GWT-Ext ComboBox loading from XML
09Jun09
This is a simple example on how to make a ComboBox in Gwt-Ext to populate with XML.
HttpProxy proxy = new HttpProxy("xml/combo_data.xml", Connection.GET);
final RecordDef recordDef = new RecordDef(new FieldDef[] {
new StringFieldDef("id"),
new StringFieldDef("value") });
XmlReader reader = new XmlReader("comboitem", recordDef);
final Store store = new Store(proxy, reader);
ComboBox combo = new ComboBox();
combo.setLabel("Combo Label");
combo.setStore(store);
combo.setDisplayField("value");
combo.setMode(ComboBox.REMOTE);
combo.setTypeAhead(true);
this.rootPanel.add(combo);
store.load();
And the xml can be seen here
Hope it helps
Filed under: ExtJs, GWT | Leave a Comment
Tags: gwt-ext
No Responses Yet to “GWT-Ext ComboBox loading from XML”