Task Scheduler: "at logon" task starts already at boot

Page 1 of 2 12 LastLast

  1. Posts : 18
    Windows 10
       #1

    Task Scheduler: "at logon" task starts already at boot


    Hi all,
    I created a task that should start at logon of any user, running a batch.

    It's almost alright, but the task runs when the computer starts, when anyone is not yet logged in...

    I can post some screenshots if needed.

    Thanks for your support
    mf
      My Computer


  2. Posts : 2,973
    Windows 10 Pro for the Bro
       #2
      My Computer


  3. Posts : 18
    Windows 10
    Thread Starter
       #3

    Hi Pepanee,
    yes, exactly this way!

    I have this behavior on every PCs I have tried...

    Consider that we have not a domain, only workgroup, win10 or win11 PCs, all the users are beloging to Administrators group.

    When the Pc starts, it runs the program foreseen from that task, even if no user is logged in...
      My Computer


  4. Posts : 2,973
    Windows 10 Pro for the Bro
       #4

    So, let's say on one of the computers that you're using, it has more than one user registered to it? (..or from what I understood, it is connected to the internet where it can log on any registered user in the network)?

    Try setting it up for one specific user:
    Task Scheduler: "at logon" task starts already at boot-image.png

    Then restart that computer. Once the computer reaches the log-in screen, log into that specific user account, and report back on what happens. Hopefully the computer executes the batch file after this specific user logs in.
      My Computer


  5. Posts : 17,015
    Windows 10 Home x64 Version 22H2 Build 19045.4170
       #5

    mfran2002 said:
    It's almost alright, but the task runs when the computer starts, when anyone is not yet logged in...
    I can post some screenshots if needed.
    Yes, please do.
    And please confirm
    - what the task definition's General tab says about running whether a user is logged on or not. Task scheduler might not be clever enough to handle that correctly for a logon task.
    -whether or not you have set up a user to login automatically.


    All the best,
    Denis
      My Computer


  6. Posts : 18
    Windows 10
    Thread Starter
       #6

    Here it is:

    this behavior is on every PC. All the PCs have at least 2 users, "Administrator" and one or more users (the colleague belonging to). The PC I'm testing has only these 2 users. All the users, also the colleagues, belongs to "Administrators" group.
    All PCs are Win10PRO or Win11PRO. The PC I'm testing is Win10PRO.
    Tried your suggestion, see below the picture, but the same. I can add that it happens only at boot, when the PC starts.
    When already started, the task runs correctly for each user.

    Task Scheduler: "at logon" task starts already at boot-screenshot.14.jpg




    - what the task definition's General tab says about running whether a user is logged on or not. Task scheduler might not be clever enough to handle that correctly for a logon task.

    Task Scheduler: "at logon" task starts already at boot-screenshot.13.jpg




    -whether or not you have set up a user to login automatically: no users logon automatically
      My Computer


  7. Posts : 17,015
    Windows 10 Home x64 Version 22H2 Build 19045.4170
       #7

    Well, there's clearly nothing wrong with your Trigger or in your General tab settings.

    I am keen to know why you say the task is running before login i.e. what is it that you observe before logon that tells you the task has started.

    All the best,
    Denis
      My Computer


  8. Posts : 18
    Windows 10
    Thread Starter
       #8

    you are right, missed this info:

    the task at logon runs a batch sending me an alert.

    also I have an alert at startup.

    So I get both alerts when PC starts, with the same times, one for startup and one for login.
    But none is loggedin....

    and when the PC is already on, everything runs fine

    I'm struggling for this.
      My Computer


  9. Posts : 2,973
    Windows 10 Pro for the Bro
       #9

    Hi, okay I don't know why Task Sceduler is acting all wonky and bonky, or whatever that word is...

    Have you thought of a different type of way to try to start the script?
    Check this idea out:
    cmd - how do i autostart batch file on windows startup - Stack Overflow

    It's the list of apps/programs/[scripts too I guess], that would start up with the log in of a specific user.
    Specifically, this thing:
    Task Scheduler: "at logon" task starts already at boot-image.png
    All these apps start up right after my user account logs in. Technically speaking, this is another alternate idea that would do the same thing you want.
      My Computer


  10. Posts : 18
    Windows 10
    Thread Starter
       #10

    I don't know the reason, but guess I found the point.

    checking every and single settings, I found a flag enalbed, by default, on each PC. Tried disabling that, and it works now.
    The weird thing is that I disabled the flag ONLY for the "normal" user, the one used by the colleagues... not from Admin.
    And it works for both.

    See below the flag for both Win10PRO and Win11PRO:


    Task Scheduler: "at logon" task starts already at boot-screenshot.16.jpg



    Task Scheduler: "at logon" task starts already at boot-screenshot.15.jpg



    I will take a look in these days and let you know if it comes back again or dfinitively sorted out...

    THANK YOU SO MUCH FOR YOUR HELP MY FRIEND!!!!

    appreciated
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 15:27.
Find Us




Windows 10 Forums