I basically want the operator to be able to select a cell from a table and enter some data and when submitted that selected value gets used in the WHERE clause so the data can be inserted in the correct row.
I want the first column selected and what I have lets me do that, my issue is if I click on any other column I get an error saying
Traceback (most recent call last):
File "<event:mouseClicked>", line 4, in <module>
TypeError: can't convert 96 to java.lang.String
96 happened to be a value in that specific cell. I even tried another cell that is a time stamp just like the first row but got the same error. I would like to click on any cell and basically get the value of the first column of that row. I was also testing with writing to a tag facing the same problem.
I’d appreciate all the help. Thanks
Thank you JGJohnson, that certainly fixed the issue with the error. How would I approach the other issue as far as only the first column value of a row being selected whenever any column of that row is selected?
could something be done here
In that case you won’t need to cast the value to string. I missed the part in your post where you said that you wanted the 1st column to be selected.
Also keep in mind that you can reference the column by name. That will keep your script from breaking if you ever change the order of columns in the table.
text = getValueAt(table.selectedRow, "mySpecialColumn")