DopeHN Posted June 11, 2012 Posted June 11, 2012 Alright as you can probably see by looking at my question I am very new at scripting and such but any ways let me tell you my situation (and yes i have looked for about an hour now and can not find an answer so i am posting here) Alright so basically i need to list certain items in the combo box (yes i do not know how to put items into the combo box (by items i mean text) and then how would i go about putting a check box next to every "item"? If you can help me with this it would be greatly appreciated. And no i haven't started on making the buttons do anything but yes i do know how Thanks! #include <ButtonConstants.au3> #include <ComboConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Include <GuiComboBox.au3> #include <Array.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Airsoft Form Creator", 421, 208, 388, 181) $hAddButton = GUICtrlCreateButton("Add", 280, 138, 30, 20) $hCombo = GUICtrlCreateCombo("", 122, 138, 145, 25) $Name = GUICtrlCreateInput("Name", 28, 38, 173, 21) $Email = GUICtrlCreateInput("Email", 28, 66, 173, 21) $Phone = GUICtrlCreateInput("Phone Number", 28, 94, 173, 21) $GunType = GUICtrlCreateInput("Gun Type", 213, 38, 185, 21) $GunProblem = GUICtrlCreateInput("Gun Problem", 213, 67, 185, 21) $AddCustomer = GUICtrlCreateButton("Add To Customer List", 212, 94, 185, 21) $Label1 = GUICtrlCreateLabel("Part List", 166, 120, 49, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd
BryanVest Posted June 11, 2012 Posted June 11, 2012 A check box next to every item I dont think is possible within a combobox, but to populate the options do this. $hCombo = GUICtrlCreateCombo("OPTION1|OPTION2|OPTION3", 122, 138, 145, 25)
DopeHN Posted June 11, 2012 Author Posted June 11, 2012 A check box next to every item I dont think is possible within a combobox, but to populate the options do this. $hCombo = GUICtrlCreateCombo("OPTION1|OPTION2|OPTION3", 122, 138, 145, 25) Thanks i realized i did not ask my question quite right well i did but i am revising my question ok so sense i am not able to do the check boxes i decided to go with a drop down box instead although this drop box instead i am now using a ListBox instead how would i go about making the list box a dropdown box? Thanks in advanced ! #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <GUIListBox.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Airsoft Form Creator", 421, 208, 375, 154) $Name = GUICtrlCreateInput("Name", 28, 38, 173, 21) $Email = GUICtrlCreateInput("Email", 28, 66, 173, 21) $Phone = GUICtrlCreateInput("Phone Number", 28, 94, 173, 21) $GunType = GUICtrlCreateInput("Gun Type", 213, 38, 185, 21) $GunProblem = GUICtrlCreateInput("Gun Problem", 213, 67, 185, 21) $AddCustomer = GUICtrlCreateButton("Add To Customer List", 212, 94, 185, 21) $Label1 = GUICtrlCreateLabel("Part's List", 166, 120, 49, 17) $List1 = GUICtrlCreateList("", 132, 146, 121, 19, BitOR($LBS_NOTIFY,$WS_VSCROLL,$WS_BORDER)) $Button1 = GUICtrlCreateButton("Add Part", 258, 148, 75, 17) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd
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