Re: Setting data cell type for a specific row
Re: Setting data cell type for a specific row
- Subject: Re: Setting data cell type for a specific row
- From: "I. Savant" <email@hidden>
- Date: Mon, 26 Jan 2009 16:51:52 -0500
On Mon, Jan 26, 2009 at 4:41 PM, <email@hidden> wrote:
> I have a table where I want a button field in the last row of a column to contain a different button cell than all the other rows. All rows before the last contain a delete button, but in the last row, I want to change that to an add button. I create the "add" button when my class in initialized so how would I get a reference to the last button cell and change it's to my saved button cell?
You don't get a reference to a cell. You tell the table view (via a
delegate method) what prototype cell to use for the requested col/row.
See:
-[NSTableView tableView:dataCellForTableColumn:row:]
... and ...
Table View Programming Guide
http://developer.apple.com/documentation/Cocoa/Conceptual/TableView/TableView.html
--
I.S.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden