Hello,
I am developing a project involving recipes and I successfully built a transaction group linked to a DB table that sends the recipe to my PLC.
What I want to do now is make a table control in a window so that the user can edit the recipes. I did that table control and I used the table customizer to make the columns editable. However as I read in the manual, to update the table an UPDATE query needs to be done. There is an example in the manual and it talks about an event called cellEdited.
In my version of Ignition (7.7.1 b2014092209), there is no such event, but there is an extension function called onCellEdidted.
Can you please guide me on what code needs to be inserted here to update my table?
Regards
Hi!
You caught me off guard for a bit on this one. Then I found out that what you have is the Power Table and not the standard Table component. 
Haven’t used it yet, but I’d say you’re on the right track.
Here’s a quickie script for updating the underlying db table. Not fully tested to where I tried to deliberately break it, but it should give you a place to start. 
[code] if oldValue != newValue:
import system
#get header names and convert to Python dataset for easy lookups.
headers=system.dataset.getColumnHeaders(self.data)
data=system.dataset.toPyDataSet(self.data)
columnName=headers[colIndex]
index=data[rowIndex]['id']
query="UPDATE rc180_errorlist SET %s='%s' WHERE id='%d'"
system.db.runUpdateQuery(query % (columnName, str(newValue), index))
[/code]