martin Posted December 1, 2006 Share Posted December 1, 2006 The DateTimeSplit function splits a date into date and time parts using " T" as a delimiter. I think this is incorrect and it should be " ". Below is a copy of the function Func _DateTimeSplit($sDate, ByRef $asDatePart, ByRef $iTimePart) Local $sDateTime Local $x ; split the Date and Time portion [color=#FF0000]$sDateTime = StringSplit($sDate, " T")[/color];<---- T??? ; split the date portion If $sDateTime[0] > 0 Then $asDatePart = StringSplit($sDateTime[1], "/-.") ; split the Time portion If $sDateTime[0] > 1 Then $iTimePart = StringSplit($sDateTime[2], ":") If UBound($iTimePart) < 4 Then ReDim $iTimePart[4] Else Dim $iTimePart[4] EndIf ; Ensure the arrays contain 4 values If UBound($asDatePart) < 4 Then ReDim $asDatePart[4] ; update the array to contain numbers not strings For $x = 1 To 3 $asDatePart[$x] = Number($asDatePart[$x]) $iTimePart[$x] = Number($iTimePart[$x]) Next Return (1) EndFunc ;==>_DateTimeSplit Does anyone agree? Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
mikehunt114 Posted December 1, 2006 Share Posted December 1, 2006 Any of these formats: "yyyy/mm/dd[ hh:mm[:ss]]" "yyyy/mm/dd[Thh:mm[:ss]]" "yyyy-mm-dd[ hh:mm[:ss]]" "yyyy-mm-dd[Thh:mm[:ss]]" "yyyy.mm.dd[ hh:mm[:ss]]" "yyyy.mm.dd[Thh:mm[:ss]]" Should it be either "T" or " "? IE Dev ToolbarMSDN: InternetExplorer ObjectMSDN: HTML/DHTML Reference Guide[quote]It is surprising what a man can do when he has to, and how little most men will do when they don't have to. - Walter Linn[/quote]--------------------[font="Franklin Gothic Medium"]Post a reproducer with less than 100 lines of code.[/font] Link to comment Share on other sites More sharing options...
Developers Jos Posted December 1, 2006 Developers Share Posted December 1, 2006 Does anyone agree?No.It splits the date and time using either a "T" or " " which we need to keep ....The T is used in the ISO standard date format ..... SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
martin Posted December 1, 2006 Author Share Posted December 1, 2006 No.It splits the date and time using either a "T" or " " which we need to keep ....The T is used in the ISO standard date format .....Ah, I see, I'm wrong. Apologies. Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. 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