Revision history [back]

click to hide/show revision 1
initial version

answered 2011-05-13 09:48:46 +0800

twiegand gravatar image twiegand

César,

One way to deal with this is just to set the selected index at create time.  Simply change your <listbox> to look like this:

<listbox rows="1" mold="select" id="lb" onCreate="self.setSelectedIndex(0)">

Then, in your alert you can do something like this to get the actual label (e.g. Inbox):

alert(lb.getSelectedItem().getLabel());

Regards,

Todd

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More