Page 1 of 1

CombBox question

Posted: Fri May 02, 2014 7:37 pm
by tasdvl9
Hello,

I'm trying to keep the items in my comboBox from being erased when I use this line of code:

set the text of button "btnAddress" to myAddrBtnTxt

However, when I look at my ComboBox button I see the other selections are no longer in the drop down box.

My question is how do I set the ComboBox so all of the other items are still listed and not overwritten?

Thanks!

Re: CombBox question

Posted: Fri May 02, 2014 8:03 pm
by magice
I think what you are looking for is the menuItem keyword.

example:

Code: Select all

select menuItem 3 of button "myComboBox"

Re: CombBox question

Posted: Fri May 02, 2014 8:51 pm
by Klaus
I rather think that you mean "the label"! :D
...
set the label of btn "your combobox here..." to "New visible Label of button"
...
This willll only change the visible part (= the label) and not the complete content!

Re: CombBox question

Posted: Fri May 02, 2014 9:13 pm
by magice
Oh yes, what Klaus said. :D
I made the assumption that you wanted the combo box to run whatever script is attached to that selection. Your line of code is more like what Klaus suggested, where you only change which selection is showing.