Run Script Once a Day
Keywords: timeymdhms once a day Timer Script Every Day startup
Question:
How would I write a script that runs once, and ONLY once a day when the user starts their machine. The problem is if they reboot at any time through out the day, I do not want the script to run again.
Answer:
Put the following script in the Windows | startup subdirectory.....
A Timer Script to Start once a day upon startup:
myinifile = "OnceADay.ini" now = TimeYMDHMS() today = StrSub(now, 1, 10) test = IniReadPvt("MAIN", "OnceADay", 0, myinifile) if test == today then exit IniWritePvt("MAIN", "OnceADay", today, myinifile) ;<<<<<< DO STUFF HERE >>>>>>> exit
Article ID: W13880Filename: Run Script Once a Day.txt