Libraries\Pictures\task scheduler demo failures.png
http://www.freeimagehosting.net/17bly
I’m running Win7/64 bit, quad core, 8GB RAM, Delphi/BDS 2006 with all patches and DelphiSpeedUp installed. My problem is that I need to have an app that works on both WinXP and Win7/WinServer2008, so your component seemed like a really useful thing. The demo worked well so we bought it.
See the linked image – when I start the demo app from the Delphi IDE I often get the “Catastrophic failure” box as the app starts, then an empty list. Toggling out of Vista mode shows me three tasks, the Adobe one and two Google ones. Toggling back gives me another catastrophic failure. I can still create demo tasks, and if I do that the full list is populated.
If I don't get the catastrophic error, I do get the "Element not found" one.
I’m pretty sure I saw the same error from the demo but toggling out of Vista mode worked so I didn’t worry about it.
If I get the catastrophic failure starting up the vista mode does not work at all - no tasks are visible. If I don't get that error starting or going into Vista mode I get the tasks shown, including the "New Task xxxxxxxx" ones that I've created.
To recover from the catastrophic error I have to reboot and that only works sometimes - the scheduler service is locked/crashed and I can't restart it via the services applet. Killing the service using Process Explorer and starting it again does not help. Once I get that error it doesn’t disappear.
A couple of minor things that it might be nice to fix:
I can’t set Active=false on TTaskScheduler in the form editor. I can set it to true, but to set it to false I have to toggle the “UseTaskScheduler1Only” property.
On the Properties window, Settings tab the caption is “Hiden” when it should say “Hidden”. Also “Start if connection Availble” should be “Available”.
The flag tfvNeedLogon is on by default when creating tasks on my machine, but you have (commented out) code to set it true if needed which is possibly a little misleading.
When supplying username+password I find I must supply the domain as part of the username (this may be because my workplace use a home network setup), otherwise I get the awful “the parameter is incorrect” error). It might be handy to add a comment to that effect.
-------
Followup: I just got the "catastrophic failure" error from my own program. It seems to have created the task, but the error is a concern.
"Catastrophic failure" error starting demo program
I'm getting this same error in my code, and the "solution" is the same - if I create a simple daily task that works, and then I can re-run the "catastrophic error" code and it works. Interestingly, it doesn't matter which executable I run the "create demo task" in, it solves the problem for all the executables that are running. So if I run my app and get the error, I can run your demo app, create the daily task and when I retry in my app that works.
To work around this I've added a "CreateAndDeleteDemoTask" method to my app and that works.
But it's annoying - any ideas what the problem is?
To work around this I've added a "CreateAndDeleteDemoTask" method to my app and that works.
But it's annoying - any ideas what the problem is?
Your demo app does this when I build it. The precompiled demo app does too. On Win7, anyway. On my WinXP virtual machine both work fine. I have a VM with Delphi 2007 and WinXP that I've started experimenting on. If the Task Scheduler service is disabled or will not run, having your component in the app means it will not start (and loading a form with the component on it crashes Delphi). That should be easy for you to reproduce, but it's a separate bug.isiticov wrote:Thank you for reporting this. Could you please create sample project as simple as possible
I've got three executables here, all built from your demo app source code. (1) the pre-built demo from your web site. (2) built by BDS2006 (3) built by BDS2007. What I notice is that the BDS2006 build is much more likely to cause the catastrophic failure error, but once I get it from that the other two builds also show it. I can bypass it by creating one of the demo tasks, but once I exit and restart I get the error again. I've zipped all three executables and put them here: http://www.filefactory.com/file/1dhq1gj ... o-bugs_zip