Eugene Gordin
Eugene Gordin

Reputation: 4107

Selection is not getting highlighted in my NSTableView table

I have a view-based table in my app. Everything works good except that when I click on the table entry the row/column I get the click and the content of my pick is sent to corresponding method, but the row is not getting highlighted.

I'm curious why is that, and can the problem be that I have a view-based table, not cell-based?!

Upvotes: 0

Views: 250

Answers (3)

Eugene Gordin
Eugene Gordin

Reputation: 4107

I found the answer to this question here thanks to Peter Hosey

How to select items in NSOutlineView without NSTreeController?

Upvotes: 0

Dhanunjay Kumar
Dhanunjay Kumar

Reputation: 91

check whether u have set the empty selection or not. if u didn't set it in code check in nib properties or try by setting this setAllowsEmptySelection:no By default setAllowsEmptySelection is YES

Upvotes: 0

Hussain Shabbir
Hussain Shabbir

Reputation: 15025

Try this:-

  - (void)selectRowIndexes:(NSIndexSet 
   *)indexes byExtendingSelection:(BOOL)extend

Upvotes: 1

Related Questions