darzanmihai Posted September 5, 2008 Share Posted September 5, 2008 Lets's say I have this script: #include <GUIConstants.au3> #include <WindowsConstants.au3> ;#include <Constants.au3> ;#include <StaticConstants.au3> $title = "My GUI UpDown" GUICreate($title,-1,-1,-1,-1, $WS_SIZEBOX) $input = GUICtrlCreateInput ("2",10,10, 50, 20) $updown = GUICtrlCreateUpdown($input) GUISetState () While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend How could I make the UpDown control increment less then 1...lets say 0.1 or 0.01 or 0.001.........? I do not like stupid and idiot people that write idiot things...If you are one, do not write. Link to comment Share on other sites More sharing options...
martin Posted September 5, 2008 Share Posted September 5, 2008 Lets's say I have this script: #include <GUIConstants.au3> #include <WindowsConstants.au3> ;#include <Constants.au3> ;#include <StaticConstants.au3> $title = "My GUI UpDown" GUICreate($title,-1,-1,-1,-1, $WS_SIZEBOX) $input = GUICtrlCreateInput ("2",10,10, 50, 20) $updown = GUICtrlCreateUpdown($input) GUISetState () While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop Wend How could I make the UpDown control increment less then 1...lets say 0.1 or 0.01 or 0.001.........? Here's one way #include <GUIConstantsex.au3> #include <WindowsConstants.au3> ;#include <Constants.au3> ;#include <StaticConstants.au3> $title = "My GUI UpDown" GUICreate($title,-1,-1,-1,-1, $WS_SIZEBOX) $inseen = GUICtrlCreateInput("0.2",10,10,50,20) $input = GUICtrlCreateInput ("2",59,10, 20, 20) $updown = GUICtrlCreateUpdown($input) ;GUICtrlSetState($input,$GUI_HIDE) GUISetState () While 1 $msg = GUIGetMsg() If $msg = $GUI_EVENT_CLOSE Then ExitLoop if $msg = $updown then GUICtrlSetData($inseen,0.1 * Number(guictrlread($input))) EndIf Wend 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