cherrylatte Posted April 11, 2016 Posted April 11, 2016 hi I'm trying to make a script that runs different functions depending on the local time of the computer I tried to do if _NowCalcDate < 2016/04/12 Then functionA() Else functionB() Endif and that doesn't seem to work. I am assuming that value returned from _NowCalcDate doesn't match with the date type I wrote What should I do? I'd appreciate for any help that's given.
Jfish Posted April 11, 2016 Posted April 11, 2016 How about this? #include <Date.au3> $diff=_dateDiff("D","2016/04/11",_NowCalcDate()) if $diff >1 then MsgBox(0,'','less than') ElseIf $diff =0 then MsgBox(0,'','same date') Else MsgBox(0,'','greater than') Endif cherrylatte 1 Build your own poker game with AutoIt: pokerlogic.au3 | Learn To Program Using FREE Tools with AutoIt
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