tamasgal
tamasgal

Reputation: 26329

Get NSTableCellView for a given row

My NSTableCellView is subclassed and storing a pointer to an Object. I want to get access to that pointer and the only information I've got is the row number as NSInteger.

How do I access an NSTableCellView from my tableView with a given row?

Upvotes: 8

Views: 4615

Answers (1)

tamasgal
tamasgal

Reputation: 26329

OK got it:

NSTableCellView *selectedCell = [tableView viewAtColumn:selectedColumn
                                                    row:selectedRow 
                                        makeIfNecessary:NO];

Upvotes: 19

Related Questions