DaLiMan Posted September 9, 2004 Share Posted September 9, 2004 I need to change System Date so now and then. ( I bet you all know why... ) Can this be done with Auto-It ??? Link to comment Share on other sites More sharing options...
Matt @ MPCS Posted September 9, 2004 Share Posted September 9, 2004 You could attempt to automate it using the windows clock, or using the DOS command: Date. *** Matt @ MPCS Link to comment Share on other sites More sharing options...
DaLiMan Posted September 9, 2004 Author Share Posted September 9, 2004 DOS [date] sounds interesting!!! Gonna work on that... Thanx Matt @ MPCS Link to comment Share on other sites More sharing options...
smasher953 Posted September 13, 2004 Share Posted September 13, 2004 I use this to set the date back 1 year for some things that we run. I write the current date to a registry key and then read that registry key to reset the date: Change date to 1 year ago: $date = @MON & "/" & @MDAY & "/" & @YEAR RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\DateChange", "Date", "REG_SZ", $date) RunWait(@ComSpec & " /c " & "date " & @MON & "/" & @MDAY & "/" & @YEAR-1, "", @SW_HIDE) Reset the date back to the current date: $date = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\DateChange", "Date") RunWait(@ComSpec & " /c " & "date " & $date, "", @SW_HIDE) Link to comment Share on other sites More sharing options...
DaLiMan Posted September 13, 2004 Author Share Posted September 13, 2004 Hi smasher953, Just copied your code to try it, but nothing happens. The Auto-It icon just remains in the tray. Could there be something different on my PC? 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