Update one (uneditable)data cell based on another (editable) data cell

OK, I’m stumped. I need to change the contents of a data cell based on a value entered in a different cell of the same row. I can’t find an end editing handler that is available for this purpose.

The same table also has a check box button cell in one of the columns, and again, I need to change a value in one of the other columns when that button is checked or unchecked. An on clicked handler doesn’t give me the parent cell or row, just the button cell itself as theObject.

Anyone have something similar, and how did you solve this?


Thanks, Jacques, I thought changed cell value might be the answer, but was not sure how to use it and the documentation of it gave no example. I had written something like yours, but it didn’t work, and that was why I posted.

The table view has a datasource, does that make a difference? I don’t think I really need the datasource, if it will prevent the cell updates I described.

I’ll take my code out and try yours and see if maybe mine was flawed somehow. When I ran the test in the debugger with my code, it seemed it was never called, even though I selected “changed cell value” in Interface Builder for the table.

I appreciate your taking the time to post!


OK, after some real digging, I have found the problem. (For reference, check the data suite docs at Apple under change cell value):

There are 2 events, named similarly, change cell value and cell value changed.

change cell value won’t be sent if the table has a datasource (according to the docs).

cell value changed wasn’t introduced until AppleScript Studio 1.4 (Tiger).

Sooo, what that means is that, since I’m on Panther, I can only use change cell value and I have to remove the datasource and do all the updates myself. Yucky, but I at least have an answer now. The info was buried in a short line in the data suite main pages, not in the individual event descriptions.

Thanks for the input, you got me digging further.