Task Scheduler 1.0 cannot launch a remote task on Windows 2008 R2
I have an application that tries to create a task on a remote computer, using Task Scheduler 1.0. This has been working on all platforms, including Windows 7 and Windows 2008 R2 but, recently, 2 different customers have been seeing the same problem: The task is properly created, but the call to launch (on demand, using ITask::Run) does not seem to be working; what I mean by that is that the return value is 0 (S_OK), but then, the calls to GetStatus keep returning S_OK, with a status of SCHED_S_TASK_HAS_NOT_RUN (0x41303) - The task has not yet run. I do not see any event that could point me to what the is the problem and why isn't the task launched. Originally, my application was creating the task without any trigger, and the GetStatus was returning a status of SCHED_S_TASK_NOT_SCHEDULED (0x41305) - One or more of the properties that are needed to run this task on a schedule have not been set. Although we have environments where that was not an issue, and I emphasize the fact that there are many customers running with no problems too, I changed the application to add a ONCE trigger (in the future), but now I get the SCHED_S_TASK_HAS_NOT_RUN error. I tried enabling the Debug and Diagnostics logs for the Task Scheduler, but I have problems reading through the events (after saving them to an .evtx file, as suggested, all logs point to "event not found" or something like that. In the 2 cases, one client was running the application on Win 7 Pro (32-bit), trying to launch the task on a Win 2008 R2 Std x64, while the other client has both computers running Win 2008 R2 Std x64. I would like to avoid changing the code to use Task Scheduler 2.0, since the application is deployed on a variety of platforms, starting with Windows 2000, and due to some time constraints. Any help will be greatly appreciated.
March 30th, 2011 7:12pm

Can you export the task as share the settings?Regards, Bill
Free Windows Admin Tool Kit Click here and download it now
April 16th, 2012 11:44pm

Check to make sure that the account that creates the task has the proper privileges on the remote server.
September 28th, 2012 5:47pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics