Getting correct data from a sorted data source
Getting correct data from a sorted data source
- Subject: Getting correct data from a sorted data source
- From: Jeffrey Mattox <email@hidden>
- Date: Wed, 29 Jan 2003 21:36:24 -0600
I have a one-column data source and a table view. The data source is
sorted. When I add items to the data source, the table view shows
them as sorted.
My problem is that when I select a row in the table view, say row 4,
and look at that row of the data source, I don't find the
corresponding data.
set theIndex to selected row of table view "x" of scroll view "y"
of window "main"
set theValue to contents of data cell "name"
of data row theIndex of theDataSource
When the data source is sorted, theIndex does not correspond to theValue.
Either I need to translate the index or fetch theValue from the table
instead of the data source, but I don't know how to do that. How can
I determine the contents of the data shown in the table view at the
selected row of the table?
Jeff
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.