Tableview with different rows


I’m hoping someone might be able to help me…

I’m trying to create a tableview that has different datasources on different rows, i.e one row has a popup cell, one may have a check box, another is a editable text field.

Does anybody out there have any examples of something similar???

Any help would be greatly appreciated.


That is not possible in AppleScript-Studio. The type of cell is not defined by the table view but by the table column. That means each row has the same table cell. The table view doesn’t use a copy for each cell displayed, for optimized performance and memory usage one table cell draws all table cells for that column.

Is it then completely impossible? No, you can subclass NSTableColumn where you can override the dataCellForRow: method with your own implementation drawing your own cell. Again, this cannot be done in AppleScript-Studio and must be done in Objective-C meaning it should be possible in AppleScriptObjC as well. As long as you don’t draw the cell yourself but subclass an NSTableColumn that supports multiple standard cells, AppleScriptObjC could be worth a try.

Thanks for the reply. I’ll take a look at AppleScriptObjC.