Hi, I am trying to update tag values when user changes them on the power table, I was able to get to work using onCellEdited function but how can do when the client is in the touchscreen mode? Here’s my power table function scripts, thanks.
onCellEdited code:
import system
self.data = system.dataset.setValue(self.data, rowIndex, colIndex, newValue)
WO = system.tag.read("[Client]FORM Recipe Mgmt Tags/FORM_part_1/Part_Work_Order").value
RC_times = system.tag.read("[Client]FORM Recipe Mgmt Tags/FORM_part_1/Recycle_freq").value
RC_start_date = system.tag.read("[Client]FORM Recipe Mgmt Tags/FORM_part_1/Recycle_start_date").value
if colIndex == 2:
system.tag.write("[Client]FORM Recipe Mgmt Tags/FORM_recycle_" + str(rowIndex+1) + "/Recycle_Lot",newValue)
system.db.runPrepUpdate("UPDATE Q_WO_RC_info SET RC_lot = ?, RC_times = ?, RC_start_date = ? WHERE Work_order = ? AND RC_no = ?", [newValue,RC_times,RC_start_date,WO,rowIndex+1])
else:
pass
onDoubleClick code:
if colIndex == 2:
if system.gui.isTouchscreenModeEnabled():
system.gui.showTouchscreenKeyboard("")
else:
pass
else:
pass