refreshBinding not working probably because not called on the right object

I’ve got a table whose data are based on a date field, so i created a binding on it.
There is also a button that adds a new row, so that when pressed I want to requery the table.
I tried with the following line of code in the button click event:

system.db.runPrepUpdate("INSERT INTO MYTABLE (COL1) VALUES (?)",[myNewData])

But it doesn’t work with the error:

org.python.core.PyException: AttributeError: 'com.inductiveautomation.perspective.gateway.script' 
object has no attribute 'refreshBindings'

Any idea?
Thanks in advance

You should be refreshing the table binding - not the lblDate binding.

1 Like

Refreshing the table binding? It makes sense.
So I tried this:


Same error:

AttributeError: 'com.inductiveautomation.perspective.gateway.script' object has no attribute 'refreshBindings'

It isn’t refreshBindings. There is no “s”

1 Like