Hello ReHa,
first of all, please do not reply to a existing question asking a new one.
The threaded view will sort in your questions as an answer of the older.
That way, your new question can easily get lost.

Now to your question: 
The use case you need can not exactly work with qooxdoo. The model is always
set by the controller which uses usually the whole model object which holds
for example the label as well. Only numbers can not work with the
controller. But that should not be a problem because you can store the
number as a property of the used model. Take a look at the code (Playground
ready) to see how you can get it done:

// UI
var selectBox = new qx.ui.form.SelectBox();
this.getRoot().add(selectBox);

// Data
var data = [{label: "a", id: 1}, {label: "b", id: 2}, {label: "c", id: 3}];
var model = qx.data.marshal.Json.createModel(data);

// controller
var controller = new qx.data.controller.List(model, selectBox, "label");

// model proof
var label = new qx.ui.basic.Label();
this.getRoot().add(label, {left: 130, top: 5});
controller.bind("selection[0].id", label, "value");

Regards,
Martin
-- 
View this message in context: 
http://qooxdoo.678.n2.nabble.com/SelectBox-set-selection-tp4798272p4973111.html
Sent from the qooxdoo mailing list archive at Nabble.com.

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

Reply via email to