field.setSelected(item_no);

Just a guess....

-Jonathan.

On 11/22/06, Aaron Cooper <[EMAIL PROTECTED]> wrote:

 Hi Guys,

Spent a good 3 hours trying to do this simple task, and can't find the way
of doing it in the API or Demos.

Take this simple Yes/No Combobox class that I have made:

function ftmDataEntryYesNo (name, xPos, initialVal) {
 var field = new qx.ui.form.ComboBox();
 field.setCssClassName("ftm-text-fields");
 field.setTop(xPos);
 field.setWidth(75);
 field.tagName = name;

 var item_no = new qx.ui.form.ListItem("No");
 item_no.setValue(0);

 var item_yes = new qx.ui.form.ListItem("Yes");
 item_yes.setValue(1);

 field.add(item_no, item_yes);

 //Set the initial value
* field.setSelected(field.getList().item_no);*

 return field;
}
What is wrong there? I know about field.getList().getLastChild(), the
above code came from a demo example using it. But how do I select a specific
child?

Cheers
Aaron

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to