Roger,
To your knowledge, is there anything special to run an exe from task scheduler on the server with ADS? The exe runs fine if started by a user from the same long path name, but the task scheduler just hangs.
Is there something not loaded or a missing path that is needed?
My client has 4 to run that were running on the non-ads. We made new exe's to load the ads, which it does, but only if started by a user.
Thanks
Fred
Omni
ADS and task scheduler
Re: ADS and task scheduler
Did you test it first by just running it on the server from a command prompt?
The eXpress train is coming - and it has more cars.
Re: ADS and task scheduler
Yes, it runs from any command prompt and using the windows run command. Only on task scheduler it does nothing, according to the user. He has to stop it using task manager.
Fred
Fred
Re: ADS and task scheduler
You probably should put some debugging in the DBESYS.PRG to see if it gets that far.
The eXpress train is coming - and it has more cars.
Re: ADS and task scheduler
I did some log writing as it goes thru the dbesys and it is successfully loading ADS according to the log.
I then did the same thing in the exe and it stops logging and everything else when it attempts to open its first dbf file.
There is no method to record an error..and cannot find why it stops there. Its a simple use command and it works running from any other location.
It locks up and has to be stopped using the task manager. There may be some sort of ADS message but using the scheduler those do not show up anywhere.
Any suggestions?
Fred
I then did the same thing in the exe and it stops logging and everything else when it attempts to open its first dbf file.
There is no method to record an error..and cannot find why it stops there. Its a simple use command and it works running from any other location.
It locks up and has to be stopped using the task manager. There may be some sort of ADS message but using the scheduler those do not show up anywhere.
Any suggestions?
Fred
Re: ADS and task scheduler
You should write out your environment to a file in your DBESYS.PRG.
WTL GetEnv('PATH')
This may help to figure out what's going on.
It could be that you have a different PATH environment when running as an app than when running as a service.
You may need to make sure that you change directories to the correct startup folder.
WTL GetEnv('PATH')
This may help to figure out what's going on.
It could be that you have a different PATH environment when running as an app than when running as a service.
You may need to make sure that you change directories to the correct startup folder.
The eXpress train is coming - and it has more cars.
Re: ADS and task scheduler
Thanks..had to do a new dbesys for these apps and also changed the default path for our app and ads. Finally worked...
Fred
Fred