1 Dec 2009 1:39 PM #1
How to auto refresh data grid.
I have a typical problem that some of you have tried to solved before and I need your helps.
I have to develop a web application that show a data grid to the user. The data grid is about Stock performance (3 mos, 6 mos, 1year, 5 year and 10 years). So each row is per stock performance. It is typical CRUD application. I have learned how to use DwrProxy (http://www.extjs.com/forum/showthread.php?t=23884) with Ext JS grid and now I am facing my next challenge: to make the grid auto refresh with new stock performance every minute (this interval is configurable).
Question: can ext js grid trigger any timeout events that make the DataStore to fetch for updated data from the server?
I appreciate if someone can help to show me the right directions or any ideas on how I can achieve this.
1 Dec 2009 1:52 PM #2
setTimeout('yourDataStore.reload();', 60000); // 60000 = 1 minute
I wonder if you defined yourDataStore inside onReady function..
place the variable definition of yourDataStore is outside of onReady function..
1 Dec 2009 7:45 PM #3
1 Dec 2009 10:02 PM #4
1 Dec 2009 11:55 PM #5
that's good idea