I have a C# program that I need to run on a scheduled basis. The program will initially load the web browser control and do some task. I have tried running the program by itself and it works well. But it will not run when called by a task scheduler job. This is my only scheduled task that requires a GUI to run. Is there a workaround to do this?
Asked
Active
Viewed 1,498 times
1
-
1In Task Scheduler, are you configuring the application to run under your user name? And are you logged on when the task is due to run? I don't think GUI applications can run when there is no Desktop for the user they are running as. – x5657 Feb 10 '16 at 23:16
-
see: http://stackoverflow.com/questions/6939548/a-workaround-for-the-fact-that-a-scheduled-task-in-windows-requires-a-user-to-be – Alireza Feb 10 '16 at 23:32
-
The application is run under an administrator account and I enable the option run even if the user is not logged on. This is the same account I use to remote to the server. – Kris Toledo Feb 11 '16 at 04:08
1 Answers
0
For you to do this you have to set up the task scheduler to "Run Only When User is logged on"
See picture:
[]1[]
More details on my blog on how to do this.

Stephen Rauch
- 47,830
- 31
- 106
- 135

SnowDeveloper
- 19
- 3