discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTableView setAction: raising an exception


From: Yen-Ju Chen
Subject: Re: NSTableView setAction: raising an exception
Date: Fri, 12 Sep 2003 12:02:46 -0400




From: James Pendergrass <James.Pendergrass@oberlin.edu>
To: discuss-gnustep@gnu.org
Subject: NSTableView setAction: raising an exception
Date: Fri, 12 Sep 2003 11:37:32 -0400 (EDT)

Hello all,
I'm trying to build a gnustep application which relies on an NSTableView
to display some data.  When the user clicks (or double clicks) on rows in
the table view, I would like to do something, so in my UI controller's
awakeFromNib I have:
        [_theTableView setTarget:self];
        [_theTableView setDoubleAction:@selector(rowDoubleClicked:)];
        [_theTableView setAction:@selector(rowClicked:)];
Where _theTableView is an IBOutlet which is connected (using Gorm) to the
NSTableView instance.  (Gorm for some reason does not see the rowClicked:
and rowDoubleClicked IBActions which are defined in the UIController.h
file, which is why I'm doing this programmatically).

The problem is that when I launch the app and it tries to load the .gorm
file, I get the exception:
        Exception occured while trying to load model: attempt to set an
action in an NSCell

 I guess that you might not connect _theTableView to the NSTableView,
 but to a NSCell.
 If you connect the outlet to NSTableView, in the Gorm Inspector,
under "connections", it should indicate that it connects to "GormNSTableView".
 Here is a screenshot which might help:
http://www.people.virginia.edu/~yc2w/GNUstep/Tutorial/en/ch13s02.html#id2976496.

 Hope it help.
 Yen-Ju

_________________________________________________________________
Get 10MB of e-mail storage! Sign up for Hotmail Extra Storage. http://join.msn.com/?PAGE=features/es





reply via email to

[Prev in Thread] Current Thread [Next in Thread]