Schedule not running when logged off
Moderators: Dorian (MJT support), JRL
Schedule not running when logged off
I am using Remote Console to log into the server and set up scripts. I am using the Administrator login which is always logged onto the server, however if I log off the script does not run. If I log back in and run the script manually it runs fine. How do I need to set up the scripts in order for them to run scheduled without me being physically logged in via Remote Desktop?
jking,
Your problem is that the moment you log onto your server using remote desktop the server's desktop goes to a windows logon screen. When you exit from the remote desktop, the server remains at the logon screen. The problem with this is that Macro Scheduler can't do any "windows" stuff when the screen is at logon. The last discussion I saw on this topic there was not a good way to get out of the logon window without user intervention. If you run a macro that does not require "windows" stuff... e.g. you're not using any GUI stuff, like waiting for windows to open or close or emulating mouse moves or pushing buttons, then your macro will probably run fine.
for example, if you connect to your server using remote desktop and start the following script, it will continue running after you close your remote destop session. You can confirm this by making the path to the file a location available to you from your computer. After you start the script and disconnect from remote desktop, use windows explorer to browse to the location of the test_remote.txt file that the script is creating. Double clicking the file should open it in notepad. Note the last number in the list, close the text file, wait 30 seconds and open the text file in notepad again. the numbers should have incremented upward indicating that the macro is indeed running even though the server is at the windows logon screen and you are not connected via remote desktop.
Let>k=0
Label>start
Let>k=k+1
//replace things in brackets with real information pertinent to your situation
Writeln>[drive letter]\[path]\test_remote.txt,wresult,%k%
If>k=100,finish
Wait>5
goto>start
Label>finish
DeleteFile>[drive letter]\[path]\test_remote.txt
I have the same issue and would be pleased to have someone tell me how to get around this.
Later,
Dick
Your problem is that the moment you log onto your server using remote desktop the server's desktop goes to a windows logon screen. When you exit from the remote desktop, the server remains at the logon screen. The problem with this is that Macro Scheduler can't do any "windows" stuff when the screen is at logon. The last discussion I saw on this topic there was not a good way to get out of the logon window without user intervention. If you run a macro that does not require "windows" stuff... e.g. you're not using any GUI stuff, like waiting for windows to open or close or emulating mouse moves or pushing buttons, then your macro will probably run fine.
for example, if you connect to your server using remote desktop and start the following script, it will continue running after you close your remote destop session. You can confirm this by making the path to the file a location available to you from your computer. After you start the script and disconnect from remote desktop, use windows explorer to browse to the location of the test_remote.txt file that the script is creating. Double clicking the file should open it in notepad. Note the last number in the list, close the text file, wait 30 seconds and open the text file in notepad again. the numbers should have incremented upward indicating that the macro is indeed running even though the server is at the windows logon screen and you are not connected via remote desktop.
Let>k=0
Label>start
Let>k=k+1
//replace things in brackets with real information pertinent to your situation
Writeln>[drive letter]\[path]\test_remote.txt,wresult,%k%
If>k=100,finish
Wait>5
goto>start
Label>finish
DeleteFile>[drive letter]\[path]\test_remote.txt
I have the same issue and would be pleased to have someone tell me how to get around this.
Later,
Dick