I'm trying to run this on a CellEdited but it does not set the value of self.data to the query below. the query is correct i test it outside. but self.data does not change, can anyone tell me why?
def onCellEdited(self, rowIndex, colIndex, colName, oldValue, newValue):
orderid = self.parent.OrderID
invoiceid = self.parent.ID
ordertype = self.parent.ordertype
locationfrom = self.parent.locationfrom
if colName == 'id' and newValue != oldValue:
if newValue == 0:
print "entro a borrar"
system.db.runNamedQuery("Orders/DeleteInvoiceTempPallet", {"PALLET_ID": old Value, "ORDER_ID": invoiceid, "ORDER_TYPE": ordertype})
self.data = system.db.runNamedQuery("Orders/SelectCustomInvoiceTempPallet", {"ORDER_ID": invoiceid, "LOCATION_FROM": locationfrom})
Thanks for pointing that out, it but it was when I pasted the code here that I made the mistake, in Igntion my code it was correct , now I have corrected here also. the print runs, and the first name query also runs, but i can't set the data property with the self.data
I have a powertable in vision with no binding,
I need to edit the X column and want to save the edited column even after client is relaunched,
now its keeping the values until i close the vision client, after i relaunch its showing me old values ( from designer probably).
Then you need to save the content somewhere. Typically, that would be a database, and you would typically use a binding to load that content back in on startup.