PDA

View Full Version : Is there any setStore() method for TreePanel?



shwetapro
2 Aug 2012, 3:15 AM
Hi,
In my case I have a template defined for a treepanel but I have to pass the actual data(dynamic data) only after certains start up tasks are completed.
So the usecase is to pass store to treepanel after condition X has occured.

Any clue how to do that?

There is getStore() method but no setStore() method.

Help and suggestions appreciated.

Thanks,
Shweta

Zdeno
2 Aug 2012, 3:35 AM
Override your TreePanel or use


Ext.apply(yourTreePanel, {
store: yourStore
});
Overwrite will use same code inside of setStore() function.

I didnt test it but basically it could work.

shwetapro
2 Aug 2012, 10:58 PM
Hi Zdeno,
Thanks it worked. :)