My recommendation would be to get away from running a GUI / windowed application from a planned task - in practice, this is crazy at all. Ideally, deploy a console version of the application that requires execution (possibly with parameter arguments) and does not require interaction with the user (or quasi-user).
If you just can’t create a “system version” of your application, then I think you have two options, both very ugly: 1) create some kind of macro script that runs instead of your program, this script can execute the program and give “click”, 2) perform a “click” at the launch of your application, invoking a button click handler (possibly based on a parameter, to give it duality in execution modes).
Grant thomas
source share