Re: Isn't there a better way to get an automated task set up to run on a terminal server 2003 and 2008??
Dear Leslie
Below is an example of the batch file that have set up:
echo %USERNAME% %DATE%%TIME% >> "C:\Program Files\Microsoft Dynamics\GP2010\macro.log"
"C:\Program Files (x86)\Microsoft Dynamics\GP2010\Dynamics.exe" Dynamicsmaintenance.set reconcile.mac "C:\Program Files (x86)\Microsoft Dynamics\GP2010\Data\DEXmaintenance.ini"
echo %errorlevel% >> "C:\Program Files\Microsoft Dynamics\GP2010\macro.log"
I get something weird on this particular server. When I am logged in and I set off the batch file manually, I can see the cmd window opened, GP opened and logged in as the user that I specified in the macro, the process run and completed, the user loggng out, GP closed and the cmd window close. I go and check the txt file and verify that the IV reconcile process ran successfully. I can with confidence say that the batch file works and the macro works.
I then set up the windows scheduled task to run. I set it to run from 2 minutes ahead and I watch the screen. I follow the process as described above and I am confident that the process runs successfully. I have the checkbox unticked that specifies "run only when logged in".
I then set the time 2 minutes ahead again and this time I log out of the terminal server. I wait for the task to complete, I log back in to the TS and I see that the task is still running and nothing has happened as expected.I have another server that runs the exact same process but on another company in GP and on that server it works perfectly while logged out or while logged in.
When I let the task run and just disconnect from the server instead of logging out, then when I log back into the TS i see that the macro fell over on the password field - and this does not happen when the task is set off and running while logged in.
I get 3 different outcomes. Why is that??? And only for this particular TS. On the other servers it works fine???
I am desperate to find a working solution for my client.
Neil