Page 1 of 1

First ListBox item selected by default

Posted: Mon Nov 23, 2009 3:40 pm
by abdou24
Hello,

I'm using a list box in my dialog sample, and would like to know how can i set the first item of my list box to be selected.
I try to play with all the control option but still cannot figure it out.
Any idea?

Posted: Mon Nov 23, 2009 3:56 pm
by MichaelNesmith
Actually, you do it by pre-setting the variable that the control is bound to, to the target value you want to have pre-selected in the control.

Posted: Mon Nov 23, 2009 4:11 pm
by abdou24
Thank you for the quick reply.
I've tried to pre-set the variable bound to the list box but still the same thing.
Here is my project

File Attached:

PPSUITEINSTALLERPROJECT.zip

Re: First ListBox item selected by default

Posted: Wed Apr 18, 2012 10:16 am
by mikKummerfeld
it does not work...any solution ?

Re: First ListBox item selected by default

Posted: Thu Apr 19, 2012 2:25 pm
by FrancescoT
Dear User,

You should set the variable that the box writes to, to the item to select.

Example:

Set Variable MYLISTBOX to Two (Where Two is one of the String Item in the listBox)

Then in "Object Behavior" of the ListBox, Write Values to Variable assign "MYLISTBOX".

Regards

Re: First ListBox item selected by default

Posted: Fri Apr 20, 2012 12:27 am
by mikKummerfeld
it works with combobox but not with listbox.

SET LISTBOXITEM to Product A does not preselect Product A

Combobox OK

Re: First ListBox item selected by default

Posted: Fri Apr 20, 2012 7:25 am
by FrancescoT
Dear User,

It works .. I have just tested!

Send me a very simple project that replicate the issue and I wiil have a look.

Regards