PDA

View Full Version : store.removeAll() empty the store but I can't reuse it !!



Severance
19 Mar 2011, 9:18 AM
Hello,

I wrote for my storeDoc linked to a List :
storeDoc.removeAll();

It empty the store, but when I add things in the store as usual :

storeDoc.add(reponse);

I don't see anything in the List !

Thanks for your help

StuartAshworth
19 Mar 2011, 12:35 PM
Try calling the refresh() method on the Ext.List.

jsveron23
19 Mar 2011, 2:15 PM
try insert(index, object).

Severance
20 Mar 2011, 1:41 AM
yeah the list.refresh() works but the scroll stay middle if it was middle...

how to set the scroll at top ?

Severance
20 Mar 2011, 3:14 AM
ok I have found :

list.scroller.setOffset({x:0,y:0});

thank you men !