I'm slightly confused here, first thing i don't see a property called view being exposed as public hence the statement ComboBox.view.setStore(store); couldn't not be written.
Secondly my problem is that i'm creating a new ComboBox();
and then calling the method setStore(), when calling the same method again should have similar behavior.
so i'm not sure why i need to do something different each time i wish create the form panel again..
Just a snippet of my code - Below is the constructor of my ComboFieldRenderer Class
public ComboFieldRenderer(boolean nullable){
ComboBox field = null;
Template tpl = new Template("<div class=\"x-combo-list-item\" id={value}>{value}</div>");
field = new ComboBox();
field.setDisplayField("value");
field.setTriggerAction(ComboBox.ALL);
field.setForceSelection(true);
field.setWidth(80);
// field.setMode(ComboBox.LOCAL);
field.setMode(ComboBox.REMOTE);
field.setEditable(false);
field.setTpl(tpl);
field.setLazyRender(true);
}
// now from my invocation class i'm calling another method init of the class which had returned me the comboBox
public void init(Object id, Object label, Object value, Object[][] values, FieldListenerAdapter listener)
{
SimpleStore store = new SimpleStore(new String[]{"value"},values);
store.load();
field.getRenderTo();
field.removeFromParent();
field.addListener(listener);
field.setId(id.toString());
field.setStore(store);
field.setValue(value.toString());
field.focus(true);
}
the problem is in the line field.setStore(store); as this is not assigning the store becuase of the check on the property isRendered() being done when invoked second time.
i'm not well versed in GWT-EXT so i'm sure this is not the best way to code but still on the face of it i think it should behave the same... whether invoked first time or nth..