Polling mode

is this property scriptable? for example, If I have an event viewer which is a table can I create a pause button that will effectively toggle the polling mode between off and relative?

No, polling mode is not scriptable. It is not a property of the table, but of the binding itself, and that is not publicly accessible.

A workaround to this would be to use system.db.refresh() function in a property change script in a timer component. The table data property should have polling mode set to off. Then in the property change script call system.db.refresh(). Then you can have a button to toggle the timer on/off.

  • set the polling mode to off in the binding of the data
  • create a button to toggle timer on/off
  • in the property change script in the timer component, call system.db.refresh(); it will look something like this:

if event.propertyName == "value": if event.newValue == 0: system.db.refresh(event.source.parent.getComponent('Table'),"data")

This will simulate polling mode on/off.