The “numeric text field” has a handy bounds checking feature built into it. Is there an easy way to do this with editable table data?
No, but you can do it in the cellEdited script. Something like:[code]value = event.newValue
row = event.row
column = event.column
if column == 1 and (value < 0 or value > 100):
system.gui.messageBox(“Please enter in a correct number”)
# your normal code[/code]
If I add some columns to the “Column Attributes Data” named minimum and maximum is there a way to read the data out of those columns for comparison testing?
I am trying to automate this as much as possible as I will be building a number of large tables.
I added two new columns to “Column Attributes Data” called minimum and maximum (both float data type). I then created a script to look up the correct minimum and maximum for the value being edited. For entries that are string type (varchar), I tell the script to skip the comparison logic and accept the value.
Is there any problem storing the minimum and maximum values in “Column Attributes Data”?
No, you can add columns. However, it just means you can’t use the table customizer any more. The table customizer will overwrite the entire dataset.