• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Novice question: How to catch button click event in Doc based app?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Novice question: How to catch button click event in Doc based app?


  • Subject: Re: Novice question: How to catch button click event in Doc based app?
  • From: Joakim Danielson <email@hidden>
  • Date: Thu, 20 Jan 2005 12:48:47 +0100

Hi

I'm not sure if I understand you correctly but if this is a standard document-based project then File's Owner, in the MyDocument nib, is an instance of your MyDocument class.

Just make sure you have defined your action method as - (IBAction) myAction: (id) sender; and that you have the latest version of MyDoucment.h in Interface Builder.

Joakim

On 2005-01-20, at 11.53, Magnus Strand wrote:

Hi!

I have created a Cocoa Doc based app project and I have added
an action method in the MyDocument class.

I would like this action to be called when a button in the doc is clicked on.
But there is no NSDocumentController instance to connect to from the button
in the NIB window?


Should I subclass NSDocumentController and make an instance and then
connect to this one? But then how do I substitute NSDocumentController with
MyDocumentController?


--
Regards,

Magnus Strand
System Developer, MSc

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Novice question: How to catch button click event in Doc based app? (From: Magnus Strand <email@hidden>)

  • Prev by Date: Re: Authorization without permanent setuid on helper
  • Next by Date: Re: Authorization without permanent setuid on helper
  • Previous by thread: Novice question: How to catch button click event in Doc based app?
  • Next by thread: MouseOver on an menu Item
  • Index(es):
    • Date
    • Thread