Results 1 to 5 of 5

Thread: Grid rows that async refresh on settimout?

  1. #1

    Default Grid rows that async refresh on settimout?

    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:

    Code:
    ...
    statusGrid.store.on('load'
                          ,function(){
                                  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.

  2. #2
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,892

    Default

    If you want to periodically refresh the whole grid: http://extjs.com/learn/Ext_FAQ_Grid#...reshing_a_grid

  3. #3

    Default

    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.

  4. #4
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,892

    Default

    You will have to write some code which does that.

  5. #5

    Default

    And I will post that code too! Thanks for volunteering.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •