lakshmiarun
29 Dec 2010, 8:51 PM
I want to display distinct values on combox. I am getting the values stores
Group Number
A 1
B 2
C 1
D 3
E 2
I want to display the Number 1,2,3. But now im getting 1,2,1,3,2. How resolve it.
Here is my code:
ListStore<StringFieldModel> store = new ListStore<StringFieldModel>();
public ComboBox<StringFieldModel> combo= new ComboBox<StringFieldModel>();
combo.setMinChars(1);
combo.setFieldLabel(ZingTrack.getUICaptions().Vehicle());
combo.setDisplayField("name");
combo.setStore(store);
combo.setTriggerAction(TriggerAction.ALL);
combo.setEmptyText(ZingTrack.getUICaptions().Vehicle());
combo.setLoadingText("Searching...");
combo.setTypeAhead(true);
combo.setSelectOnFocus(true);
combo.setEditable(false);
combo.setHideTrigger(false);
combo.setWidth(150);
Group Number
A 1
B 2
C 1
D 3
E 2
I want to display the Number 1,2,3. But now im getting 1,2,1,3,2. How resolve it.
Here is my code:
ListStore<StringFieldModel> store = new ListStore<StringFieldModel>();
public ComboBox<StringFieldModel> combo= new ComboBox<StringFieldModel>();
combo.setMinChars(1);
combo.setFieldLabel(ZingTrack.getUICaptions().Vehicle());
combo.setDisplayField("name");
combo.setStore(store);
combo.setTriggerAction(TriggerAction.ALL);
combo.setEmptyText(ZingTrack.getUICaptions().Vehicle());
combo.setLoadingText("Searching...");
combo.setTypeAhead(true);
combo.setSelectOnFocus(true);
combo.setEditable(false);
combo.setHideTrigger(false);
combo.setWidth(150);