Re: NSTableView reloadData problem (needing 2 TableViews)
Re: NSTableView reloadData problem (needing 2 TableViews)
- Subject: Re: NSTableView reloadData problem (needing 2 TableViews)
- From: Roarke Lynch <email@hidden>
- Date: Mon, 25 Nov 2002 22:13:08 -0500
On Monday, November 25, 2002, at 06:16 PM, Raymund Beyer wrote:
- (id) tableView: (NSTableView *)tableView objectValueForTableColumn:
(NSTableColumn *)tableColumn row: (int)row;
I need 2 table views, thats why I dont have the methods for the second
on
in the controller, but in the data object. Is there a problem with
that.
Your controller object/datasource has IBOutlets to the tableViews yes?
You can use this method by just comparing the tableView to the IBOutlet
instances your object has. i.e
- (id)tableView:(NSTableView *)tableView
objectValueForTableColumn:(NSTableColumn *) row:(int)row
{
if(tableView == myFirstTable)
return dataForFirstTable;
else if(tableView == mySecondTable)
return dataForSecondTable;
return nil;
}
You are comparing the pointers of tableView objects, but they are the
same value as they should be pointing to the same object.
Roarke Lynch
-------------------------------
email@hidden
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.