aidbr Posted January 28, 2012 Share Posted January 28, 2012 Hi, i wrote a script to activate standby mode using api function call shutdown. After this statement the Script should write an entry to a logfile. The problem: The shutdown command is the last statement of the script which is executed before standby. The output command ist executed after wakeup. The script stays in memory during standby. Is it possible to schedule the shutdown command to ensure that the script has finished before standby? Link to comment Share on other sites More sharing options...
FaridAgl Posted January 28, 2012 Share Posted January 28, 2012 (edited) What do you want to write in log file? If it's not about the stand-by maybe you can do it before stand-by. BTW, if i know what is the info that you want to write in log file i can help you more effective. Edited January 28, 2012 by D4RKON3 http://faridaghili.ir Link to comment Share on other sites More sharing options...
hannes08 Posted January 28, 2012 Share Posted January 28, 2012 Maybe if yoU#d show us a little bit of your code, we could see into it. Regards,Hannes[spoiler]If you can't convince them, confuse them![/spoiler] Link to comment Share on other sites More sharing options...
aidbr Posted January 28, 2012 Author Share Posted January 28, 2012 Well, i tested this behavior with this script: Shutdown (32) WriteLog ("Test") The function WriteLog writes Text to a logfile. I only used this for testing purposes to check if script is terminated before standby. The main problem is: Sometimes the Shutdown function is executed again after wakeup, even if it's the last line of code in the script. In this case PC goes to standby immediately after waking up. It seems that script remains in memory with a wrong "execution pointer". Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now