That sounds very like the scenario I had with TaskScheduler. I run the .application with syswows\cmd.exe /C successfully where it is basically being run in a protected (emulated) 32 bit environment. This is necessary because scheduler expects a 64 bit application. There is some very limited documentation on it spread around various forums, and it may relate to some way in your 'default opener' situation.
(Edit:
Here is some of the 'deeper' discussion behind the problem to which I am referring. It may not be what lies behind this issue - though it sounds similar, but at least if you know where to start looking to check it out, it will save some time - http://blog.zachsaw.com/...dcontext-may-return.html )
Running the .application natively with a double click from a system folder is no problem.
My main issues with MSTaskScheduler are its inability to *update* the 'time' of an event; and the syntactic horror of creating an event of the type I need from within C# given the awful state of the API (unless I have missed something) and the need to run it with the cmd.exe /C syntax.
I can run as a shell exec for now - that isn't an issue, and seems to work - so I will move on to trying to create the event using the VisualCron API and see if I run into issues there. As long as I can create or update an event, and it runs - even as a shell exec, then I get what I need - but I guess you need to look into the .application thing because it won't be just me.
(Edit2); I pulled the .EXE file and ran that instead (hadn't realised it was also produced!). That seems to run in VisualCron and produces the expected output - except that having finished its job, the executable is still in the process list and VisualCron still identifies it as running - did some of the changes to the exec screen prevent a clean exit here? So I recreated the job from scratch and after selecting to run in a hidden window I have what appears to be success!
Edited by user
2011-09-22T17:23:59Z
|
Reason: Not specified