Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

DateTimePicker keeps returning 0.

$
0
0
Hello.  I am working with the DateTimePicker control and am having some difficulty reading the current date.  I am following the example the in AutoIT function documentation, and it's my understanding that  the _GUICtrlDTP_GetSystemTime() function is supposed to return the currently selected date & time as an array.  I have a button on  my form that the user will click after selecting the date of their choice from the datepicker that executes the following code.

[ autoit ]      
Func _LoadCallLog () Global $dateLogs, $mySelectedDay[7] = [False, @YEAR, 8, 19, 21, 57, 34] $mySelectedDay = _GUICtrlDTP_GetSystemTime($dateLogs) $myLogFileName = StringFormat("%02d-%02d-%04d", $mySelectedDay[1], $mySelectedDay[2], $mySelectedDay[0]) Msgbox (16,"", $myLogFileName) ;rest of my code below that will load the log file for the user to view EndFunc

However, regardless of the date selected in the datepicker control, $myLogFilename always returns a value of "00-00-00".  Is there something simple I am missing here?

$dateLogs is the name of my datepicker control.  Thanks for any assistance showing me the error.  

-hogfan

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>