Maffe811 0 Posted June 28, 2011 Below is my script and it has an up and down button. But how can i make the two little arrows at the far right of the input that thoose things usually has? Anyone get what i mean? Ill se if i can find an example. #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> Global $Counter = 0 #Region ### START Koda GUI section ### Form= $Gui = GUICreate("",170,70) $Input = GUICtrlCreateInput($Counter, 10, 10, 150, 21) $UpButton = GUICtrlCreateButton("Up", 10, 36, 70, 25, $WS_GROUP) $DownButton = GUICtrlCreateButton("Down",90, 36, 70, 25, $WS_GROUP) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $UpButton $Counter += 1 GUICtrlSetData($Input,$Counter) Case $DownButton If $Counter >= 1 then $Counter -= 1 GUICtrlSetData($Input,$Counter) EndSwitch WEnd [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Share this post Link to post Share on other sites
Melba23 3,457 Posted June 28, 2011 Maffe811,Look at GUICtrlCreateUpDown in the Help file. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Share this post Link to post Share on other sites
Maffe811 0 Posted June 28, 2011 Thank you! I was looking at different input styles. [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Share this post Link to post Share on other sites
Maffe811 0 Posted June 28, 2011 Works like i want it to: #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <GUIConstantsEx.au3> Global $Counter = 0 #Region ### START Koda GUI section ### Form= $Gui = GUICreate("",170,65) $Input = GUICtrlCreateInput($Counter, 10, 10, 150, 20, BitOR($ES_CENTER,$ES_NUMBER)) $UpDown = GUICtrlCreateUpdown($Input) $OkButton = GUICtrlCreateButton("Ok",170/2-90/2,35, 90, 25, $WS_GROUP) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $OkButton MsgBox("","",GUICtrlRead($Input)) EndSwitch If GUICtrlRead($Input) > 50 then GUICtrlSetData($Input,50) If GUICtrlRead($Input) < 0 then GUICtrlSetData($Input,0) WEnd [font="helvetica, arial, sans-serif"]Hobby graphics artist, using gimp.Automating pc stuff, using AutoIt.Listening to music, using Grooveshark.[/font]Scripts:[spoiler]Simple ScreenshotSaves you alot of trouble when taking a screenshot!Don't remember what happened with this, but aperantly the exe is all i got.If you don't want to run it, simply don't._IsRun UDFIt figures out if the script has ben ran before based on the info in a ini file.If you don't want to use exactly what i wrote, you can use it as inspiration.[/spoiler] Share this post Link to post Share on other sites