ur Posted February 8, 2017 Posted February 8, 2017 To get the current time stamp, I got the below code. #include <Date.au3> #include <MsgBoxConstants.au3> #include <WindowsConstants.au3> #RequireAdmin ; Under Vista the Windows API "SetSystemTime" may be rejected due to system security $td = _Date_Time_GetSystemTime() $td = _Date_Time_SystemTimeToDateTimeStr($td) $td = StringReplace($td, " ", "_") $td = StringReplace($td, ":", "_") MsgBox(0,"",$td) But it is not giving the date or time of the timezone where the system is there. Please suggestt
jguinch Posted February 8, 2017 Posted February 8, 2017 ConsoleWrite(@MON & "/" & @MDAY & "/" & @YEAR & "_" & @HOUR & "_" & @MIN & "_" & @SEC) Spoiler Network configuration UDF, _DirGetSizeByExtension, _UninstallList Firefox ConfigurationArray multi-dimensions, Printer Management UDF
ur Posted February 8, 2017 Author Posted February 8, 2017 2 minutes ago, jguinch said: ConsoleWrite(@MON & "/" & @MDAY & "/" & @YEAR & "_" & @HOUR & "_" & @MIN & "_" & @SEC) THanks @jguinch But in the meanwhile I have replaced my code with the below one. Func TodayDateTime() $td = _DateTimeFormat(_NowCalc(), 0) $td = StringReplace($td, " ", "_") $td = StringReplace($td, ":", "-") return $td EndFunc
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