View Full Version : Grid rows that async refresh on settimout?

11 Sep 2008, 2:07 AM
I've got a gridpanel, used for monitoring, with a large-ish record set, where each row is the result of a lookup that (row-by-row) can take up to a few seconds. The grid needs to stay up to date and what I've come up with so far is:

1. Grid populates with required rows, and each row is essentially empty apart from a basic id and name.

2. As part of init function, a request fires off for each record, goes away and starts populating the grid row by row, thusly:

statusGrid.store.data.each(function(){ Ext.Ajax.request({

So far so good. The grid "fills" asynchronously with the results of each row lookup.

What I would now like to achieve is that each row, after it finishes populating, continues to reload every n seconds. This is wher I'm stuck.

I'm not sure if my implementation is correct, this is literally my first foray into extjs.

11 Sep 2008, 2:43 AM
If you want to periodically refresh the whole grid: http://extjs.com/learn/Ext_FAQ_Grid#Automatically_refreshing_a_grid

11 Sep 2008, 3:34 AM
I want each row to wait until it's populated, then wait say 30 seconds, and then refresh just that row. Such that each row refreshes asynchronously.

11 Sep 2008, 4:03 AM
You will have to write some code which does that.

11 Sep 2008, 4:11 AM
And I will post that code too! Thanks for volunteering.