firstly, I'm using a Mac and the form designer.
I can add a combobox, and add items to the combobox, but when I test the form, no default item is displayed. When I click on the dropdown, the two options are in the drop down list, and then when I select something it stays there, but I can't start the form with a default item displayed.
Also, where to I modify the code so changes are not wiped when the form designer runs each time?
Any assistance for a PureBasic N00b would be appreciated.
Best regards
ComboBox Very simple answer I'm sure
-
- User
- Posts: 24
- Joined: Mon May 30, 2011 12:17 pm
ComboBox Very simple answer I'm sure
Andrew Lindsay
-----------------------------------------
-----------------------------------------
Re: ComboBox Very simple answer I'm sure
Form designer only preview form.
To run it and set default option, you need to make a program that call it
1. Save your form
2. Open new file that call form file
That's all

To run it and set default option, you need to make a program that call it
1. Save your form
2. Open new file that call form file
Code: Select all
; Call your form file
XIncludeFile "your_form.pbf"
; Call function to open main window
OpenWindow_0()
; Define line you want to display by default for your combobox (0 = first)
SetGadgetState(#Combo_0, 0)
; Do a loop
While WaitWindowEvent() <> #PB_Event_CloseWindow : Wend
