Irritating text view/scroll view bug. need workaround

hey there.
in my application, i have a table view on the left and a tab view on the right with various fields (mostly text fields) that the user will type in to populate the cells on the left when the end edit event is triggered. The cell columns have the same name as the name of the entry fields, so I have this very simple end edit event:


on end editing theObject
	--make sure at least one row exists before applying values to the table
	if the (count of data rows of the data source of table view "fileList" of scroll view "fileList" of window "theMainWindow") is greater than 0 then
		set selectedRow to the selected data row of the table view "fileList" of scroll view "fileList" of window "theMainWindow"
		set the content of the data cell (name of theObject) of the selectedRow to the content of theObject
		
	end if
end end editing

the problem is this:
all of the text fields update the cell for the row they are in properly.
however, I have one text view in a scroll view where some more lengthly text might get entered.
if the user first enters text here. clicks another field so the end edit even is fired, then changes to another table row, and edits the same field, one would expect it to update the data cell in the currently selected row, which it does. however, it also replaces the contents of every other cell in that column with the new value. This behaviour does not occur for text fields, only text views within a scroll view. if i delete the text view and insert a text field of the appropriate name, it works as expected. this seems to me to be some sort of bug with the text view object. Can anyone suggest a workaround for this please? i need a larger text area than a text field can provide, but this bug is a show stopper for my application.

after fighting with this all night. i finally found a simple solution.
aparrantly, for seom reason or another some erroneous data is included when calling the name of the theObject when theObject is a text view. forcing the name as string solved the problem for me.


on end editing theObject
--make sure at least one row exists before applying values to the table
if the (count of data rows of the data source of table view "fileList" of scroll view "fileList" of window "theMainWindow") is greater than 0 then
set selectedRow to the selected data row of the table view "fileList" of scroll view "fileList" of window "theMainWindow"
set the content of the data cell (name of theObject as string) of the selectedRow to (content of theObject as string)
end if
end end editing