Edit Database with Power Table

Hi, I did this like the example but I have an error…

https://docs.inductiveautomation.com/display/DOC80/Updating+the+Database+through+the+Power+Table

Someone had the same problem ? Could you help me ? Thanks

10:40:00.545 [AWT-EventQueue-0] ERROR Vision.Components.AdvancedTable - Error invoking extension method.
com.inductiveautomation.ignition.common.script.JythonExecException: NameError: name 'self' is not defined
	at org.python.core.Py.NameError(Py.java:261)
	at org.python.core.PyFrame.getname(PyFrame.java:257)
	at org.python.pycode._pyx11.f$0(<extension-method onCellEdited>:31)
	at org.python.pycode._pyx11.call_function(<extension-method onCellEdited>)
	at org.python.core.PyTableCode.call(PyTableCode.java:173)
	at org.python.core.PyCode.call(PyCode.java:18)
	at org.python.core.Py.runCode(Py.java:1687)
	at com.inductiveautomation.ignition.common.script.ScriptManager.runCode(ScriptManager.java:806)
	at com.inductiveautomation.vision.api.client.components.model.ExtensionFunction.invoke(ExtensionFunction.java:137)
	at com.inductiveautomation.factorypmi.application.components.VisionAdvancedTable$Model.setValueAt(VisionAdvancedTable.java:1807)
	at com.jidesoft.grid.TableModelWrapperImpl.setValueAt(Unknown Source)
	at com.jidesoft.grid.DefaultTableModelWrapper.setValueAt(Unknown Source)
	at com.jidesoft.grid.TableModelWrapperImpl.setValueAt(Unknown Source)
	at com.jidesoft.grid.DefaultTableModelWrapper.setValueAt(Unknown Source)
	at java.desktop/javax.swing.JTable.setValueAt(Unknown Source)
	at com.jidesoft.grid.JideTable.editingStopped(Unknown Source)
	at java.desktop/javax.swing.AbstractCellEditor.fireEditingStopped(Unknown Source)
	at java.desktop/javax.swing.DefaultCellEditor$EditorDelegate.stopCellEditing(Unknown Source)
	at java.desktop/javax.swing.DefaultCellEditor.stopCellEditing(Unknown Source)
	at java.desktop/javax.swing.DefaultCellEditor$EditorDelegate.actionPerformed(Unknown Source)
	at java.desktop/javax.swing.JTextField.fireActionPerformed(Unknown Source)
	at java.desktop/javax.swing.JTextField.postActionEvent(Unknown Source)
	at java.desktop/javax.swing.JTextField$NotifyAction.actionPerformed(Unknown Source)
	at java.desktop/javax.swing.SwingUtilities.notifyAction(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyBinding(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyBindings(Unknown Source)
	at java.desktop/javax.swing.JComponent.processKeyEvent(Unknown Source)
	at java.desktop/java.awt.Component.processEvent(Unknown Source)
	at java.desktop/java.awt.Container.processEvent(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
	at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.Component.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$4.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.desktop/java.awt.EventQueue$5.run(Unknown Source)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)
Caused by: org.python.core.PyException: NameError: name 'self' is not defined
	... 58 common frames omitted

Problem solved :In the link do not mention the line in yellow.

Thanks

1 Like