Kyan Posted March 14, 2015 Share Posted March 14, 2015 Hey, can someone tell me what I'm doing wrong here? I'm using 3 "updown" controls to set the desired date, but when it comes to year (4digits) when I change the value it becomes a decimal number Clean up gui to show the issue: #include <EditConstants.au3> $Form1 = GUICreate("Form1", 250, 50) $input1 = GUICtrlCreateInput(@YEAR, 100, 10, 50, 21, BitOR($GUI_SS_DEFAULT_INPUT,$ES_CENTER,$ES_NUMBER,$ES_NOHIDESEL,$ES_READONLY)) $btn = GUICtrlCreateButton("Read",160,10,40,21) GUICtrlCreateUpdown($input1) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case -3 Exit Case $btn MsgBox(0,'',GUICtrlRead($input1)) EndSwitch WEnd Am I doing something wrong? Thanks in advance Heroes, there is no such thing One day I'll discover what IE.au3 has of special for so many users using it.C'mon there's InetRead and WinHTTP, way better Link to comment Share on other sites More sharing options...
Solution Tekk Posted March 14, 2015 Solution Share Posted March 14, 2015 Try this: #include <UpDownConstants.au3> GUICtrlCreateUpdown($input1, $UDS_NOTHOUSANDS) Kyan 1 Link to comment Share on other sites More sharing options...
Kyan Posted March 14, 2015 Author Share Posted March 14, 2015 I don't know why it is default --", thank you very much Tekk #include <EditConstants.au3> $Form1 = GUICreate("Form1", 250, 50) $input1 = GUICtrlCreateInput(@YEAR, 100, 10, 50, 21, BitOR($GUI_SS_DEFAULT_INPUT,$ES_CENTER,$ES_NUMBER,$ES_NOHIDESEL,$ES_READONLY)) $btn = GUICtrlCreateButton("Read",160,10,40,21) GUICtrlCreateUpdown($input1,0x0080) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case -3 Exit Case $btn MsgBox(0,'',GUICtrlRead($input1)) EndSwitch WEnd Heroes, there is no such thing One day I'll discover what IE.au3 has of special for so many users using it.C'mon there's InetRead and WinHTTP, way better 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