bbg5ne
11 Jan 2010, 4:47 AM
Hi!
I have a problem with SimpleComboBox.
This is my code:
public static Field<?> getField(final ResultsetField field, List<?> values, int labelWidth, boolean textarea) {
...
final SimpleComboBox f;
if ((fieldType.compareToIgnoreCase("int") == 0)) {
f = new SimpleComboBox<Integer>();
f.setTriggerAction(TriggerAction.ALL);
f.add(values);
} else {
f = new SimpleComboBox<String>();
f.setTriggerAction(TriggerAction.ALL);
f.add(values);
}
...
The problem is this, in the simpleComboBox I find all the value, but if the values is a list of Strings I can see the selected value, if they are Ints I see all values in simpleComboBox but I have not a value selected.
Can you help me?
Thanks
Mk
I have a problem with SimpleComboBox.
This is my code:
public static Field<?> getField(final ResultsetField field, List<?> values, int labelWidth, boolean textarea) {
...
final SimpleComboBox f;
if ((fieldType.compareToIgnoreCase("int") == 0)) {
f = new SimpleComboBox<Integer>();
f.setTriggerAction(TriggerAction.ALL);
f.add(values);
} else {
f = new SimpleComboBox<String>();
f.setTriggerAction(TriggerAction.ALL);
f.add(values);
}
...
The problem is this, in the simpleComboBox I find all the value, but if the values is a list of Strings I can see the selected value, if they are Ints I see all values in simpleComboBox but I have not a value selected.
Can you help me?
Thanks
Mk