Re: Cocoa beginner question
Re: Cocoa beginner question
- Subject: Re: Cocoa beginner question
- From: email@hidden
- Date: Sat, 1 Dec 2001 03:58:11 -0500
On Wednesday, November 28, 2001, at 06:44 , Hussein Yahia wrote:
I create a simple cocoa app with PB. Using IB, I connect the "open"
menu to the action in FirstResponder : "openDocument". When I test it
under IB, if I choose "Open" in the menu, everything goes as expected :
it display s a window for opening a file. But if I compile the app in
PB, the "open" menu remains dimmed.
How to solve that ?
You need to implement openDocument: somewhere in your responder chain,
or create a document-based project and NSDocument implements it for you.
It worked in Interface Builder because IB implements openDocument:, so
the connection was valid. A menu item automatically dims when no object
in the responder chain implements its action.
Hope that helps,
Itrat.
..................................................................
Itrat Khan
Modeless Software, Inc.
http://www.modeless-software.com