What "user" must a scheduled task run as in order to be visible for all users?
I just tested this and you can select a "group" for the account.
Pick Run only when user is logged on
.
Click Change user or group (it says group right there :)
type in users
and click Check Names and Click Ok
and you application will run interactively for all users in the group users
.
Related videos on Youtube
MrWhite
Updated on September 18, 2022Comments
-
MrWhite over 1 year
I wish a task to be scheduled to run when any user logs on, but is not dependent on any one user being logged on, so I pick "Run whether user is logged on or not". The problem with this is that the program runs hidden (as stated in the docs and queried in this Microsoft Community post), but I need the GUI to be visible.
So, I need to pick "Run only when user is logged on" for it to be visible. But any one "normal" user might not be logged on!
Which user account should I use in order to run this task?
I tried running it as SYSTEM, but that automatically sets the "Run whether user is logged on or not" option - so it will run hidden.
-
MrWhite over 10 yearsThanks, I think this is the preferred the solution. (However, in my particular case there were a few added complications that I didn't mention... 1. Only one instance of the task/program should run, so whilst the GUI appears for the first logged on user, it is not visible to the second user unless they run a new instance. 2. This program also requires admin privileges, so when a non-admin user logs on first they get pestered with UAC.)
-
Rik over 10 years2) The non-admin users would always get the UAC of course. If you don't want non-admin users to run the program at logon you could always use the
Administrator
-group instead. For point 1) I take it you're using "Fast user switching"? You could disable this forcing the users to logoff before another can logon. -
MrWhite over 10 years2) If the task is set to run as AnAdminUser (with the "highest privileges") then a normal user doesn't get prompted by UAC, but neither do they see the GUI - it is hidden - which doesn't help either. 1) "Fast user switching" is preferable in this instance. I'm going to settle for running this program only by the main admin user and accept that normal users just won't see the GUI (which is really for information only), it's a compromise, but OK. Thanks for the info.
-
t3chb0t about 2 yearsMhmm... for me it worked only when I set the account to
LOCAL SERVICE
. It then automatically switches the option to Run whether user is logged on or not on. WithUsers
I had no luck.