I'm very new to cocoa and objective C. I'm hoping someone can shed some light on how to use the TableView.
I actually have gotten a TableView to display (sort of) in my tiny, new application. But, the values are always empty. It has the right number of rows, but my implementation of objectValueForTableColumn: always gets nill for [tc identifier], which doesn't make any sense to me. It should have the names of the columns I identified like this:
[myTable tableColumnWithIdentifier:@"Percent"];
Am I supposed to do something special in interface builder to identify the outlet for each column in the TableView object? Or, am I supposed to do something in interface builder to assign the same names there that I did with my tableColumnWithIdentifier call?
My array of objects has data, and the objectValueForTableColumn method is getting called when it should, but until [tc identifier] tells me a column identifier, I won't be able to return data for the column.
Thanks for any useful help you can provide.
I actually have gotten a TableView to display (sort of) in my tiny, new application. But, the values are always empty. It has the right number of rows, but my implementation of objectValueForTableColumn: always gets nill for [tc identifier], which doesn't make any sense to me. It should have the names of the columns I identified like this:
[myTable tableColumnWithIdentifier:@"Percent"];
Am I supposed to do something special in interface builder to identify the outlet for each column in the TableView object? Or, am I supposed to do something in interface builder to assign the same names there that I did with my tableColumnWithIdentifier call?
My array of objects has data, and the objectValueForTableColumn method is getting called when it should, but until [tc identifier] tells me a column identifier, I won't be able to return data for the column.
Thanks for any useful help you can provide.
-
Re: question about table view
Mon, December 10, 2007 - 8:08 PMOK, I finally found the answer by looking in detail at how one of the examples (PubSub/NewsReader) was created. What I was missing was going into the "Table Column Attributes" tab for each of the columns in my table view and entering a string for the "identifier" field. This then becomes the identifier for the column, which shows up in the [tc identifier] call.