twbradio Posted April 21, 2006 Posted April 21, 2006 (edited) What format should the data be in to properly update a date control - I am making the assumption that the form GUICtrlSetData ($datecontrol, #a valid date#) is the format, but I can't seem to figure out what the language wants for #a valid date#. 20060421 2006/04/21 04/21/2006 I know I'll go " but of course :"> " when I hear the answer - so please be kind Thomas Brown Edited April 21, 2006 by twbradio Anyone have a TRS 80 Model III for sale?
Moderators big_daddy Posted April 21, 2006 Moderators Posted April 21, 2006 This should give you an idea. #include <GUIConstants.au3> GUICreate("My GUI get date", 200, 200, 800, 200) $date = GUICtrlCreateDate("1953/04/25", 10, 10, 185, 20) $button = GUICtrlCreateButton("Change", 10, 40) ; to select a specific default format $DTM_SETFORMAT = 0x1005 $style = "yyyy/MM/dd HH:mm:s" GUICtrlSendMsg($date, $DTM_SETFORMAT, 0, $style) GUISetState() While GUIGetMsg() <> $GUI_EVENT_CLOSE Select Case GUIGetMsg() == $button GUICtrlSetData($date, "2006/04/21") EndSelect WEnd
twbradio Posted April 21, 2006 Author Posted April 21, 2006 Thank you very much - this is my first go around with the date control, and for some reason I just couldn't get it right. Tom Anyone have a TRS 80 Model III for sale?
Moderators big_daddy Posted April 21, 2006 Moderators Posted April 21, 2006 (edited) Thank you very much - this is my first go around with the date control, and for some reason I just couldn't get it right.TomIt was mine too, I just have good research skills. Glad I could help.p.s. why are you looking for a computer from the 80s?TRS-80 Model IIIIntroduced: July 1980CPU: Zilog Z-80, 2.03 MHz (smokin!!!)RAM: 48KPorts: Tape (500 or 1500 bauds), Parallel & RS232Display: 12" B/W monitor built-in: 16 X 64 textStorage: Two internal 178K floppy drives, External hard driveOperating System: TRS-DOS. Edited April 21, 2006 by big_daddy
twbradio Posted April 21, 2006 Author Posted April 21, 2006 p.s. why are you looking for a computer from the 80s?I took my first programming course in '83 on a TRS 80 model III - mostly, it's just a joke ... but there is a certain amount of nostalga involved as well.Tom Anyone have a TRS 80 Model III for sale?
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