Auto refresh a Table Pane

Hi

Please can someone send me an example of how to auto refresh a table pane. 

Thanks

Nigel

  • 0
  • 0
  • 255
  • 2
  • 0

Comments

Hi Nagel,

You can add a timer to the page and when the timer fires, refresh the tablePane with table.refreshContents() where 'table' is the table object. You may also want to clear the selection if any.

Heloisa

Hi

 

WRC helped answer this:

 

Here is the code to build into your TablePane form:

 

ClientMethod onloadHandler() [ Language = javascript ]
{
zenPage.IntervalRefresh();
myVar1 setInterval(zenPage.IntervalRefresh,1000);
}

ClientMethod IntervalRefresh() [ Language = javascript ]
{

var table zenPage.getComponentById('TableName');
//Optional if Snapshot is used
table.executeQuery()
table.refreshContents()
}

Note that the line table.executeQuery() is only required if your TablePane uses snapshot mode

 

Nigel