Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DLL Talk / BlueGUI - ComboBox

Author
Message
RegenProZ
18
Years of Service
User Offline
Joined: 20th Aug 2005
Location:
Posted: 25th Aug 2005 15:00
Sorry to ask yet another question (call me a noob as you wish)

I have a combo box, what I would like to do, is goto a different page, depending on what they select.

Lets take for instance, the question says "What is your age" and inside the combo box it has "Below 13" and "13 And Above"

what sort of command would I be looking for, to get a..

if the combo item is Below 13, then .....
if the combo item is Above 13, then .....

Catch my drift?

Thnx


---------
Cheers
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 25th Aug 2005 15:58
selectedItem
int item=selectedItem(handle gadget)

Description:
Returns the index of the currently selected item in a listbox or combobox.


Return Value:

Index of currently selected item or -1 if no item is selected.

You simply need to know the index of each option to check against

Xolatron old
20
Years of Service
User Offline
Joined: 25th Jan 2004
Location: The Star Forge Language: DBpro
Posted: 26th Aug 2005 01:42
Or for the text you can use itemText in conjunction with BatVBink's code:

To get the text of the current item. This is a little slower though (insignificant if not used inside of a loop). I use it when I load the combobox from certain files in a folder.

-Xol


DBpro IonRay IDE: Demo 0.1.0.0 available!

Login to post a reply

Server time is: 2024-05-06 06:35:41
Your offset time is: 2024-05-06 06:35:41