Cocoa Table Question

Discussion in 'Mac Programming' started by Eraserhead, Aug 24, 2006.

  1. macrumors G4


    I am (trying to) create a Cocoa app atm, and have a table I would like to display. In the first column I would like to simply display the entry number (starting from 1 if possible, like how it is displayed in Interface Builder.) and in the second the relevant value. I am reading through Cocoa, Programming for OS X (which is excellent) and this seems similar to the RaiseMan Application except that I just want the entry number instead of the persons name in the first column. How would you code this?

  2. macrumors 6502

    Take a look at the NSTableView documentation. Look specifically at the

    -(id)tableView:(NSTableView *)aTableView objectValueForTableColumn:(NSTableColumn *)aTableColumn row:(int)rowIndex
  3. macrumors G4


    Thanks, I should be able to get it sorted.

Share This Page