hey all, i am a definate noob to scripting here. I found this after I was messing with an Andy bot for diablo II and wanted to try my own tweaks.
Below is my attempt to run any file (another .au3 script, or anything else) at a certain time that is specifed. the reason I did it this way is because from what I was seeing, the Run() command doesn't work with other scripts.... which is why I got into autoit in the first place
basically to do things when I am not here :-D
lemme know what you guys thing and post some major improvements to it if you wish (plz!)
Thanks :-D
;Runs Anything at a certain time
#include <Date.au3>
$program = FileOpenDialog("Choose file...","My Computer","All")
$time = InputBox("Time", "What time would you like it to run?" & @CRLF & "hh:mm:ss AM/PM", _NowTime(), "")
$count = 0
while $time > 0
if $time = _NowTime() Then
Send("#r")
WinWaitActive("Run")
Send($program & "{Enter}")
$count = $count + 1
Sleep(1000)
EndIf
Wend
One problem I have seen, the script does not end after the program runs, the autoit is still in a tray icon for the script, anyone shed some light as to what is keeping this script alive after the while loop is done?