• 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: NSApplication delegate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSApplication delegate


  • Subject: Re: NSApplication delegate
  • From: "John C. Randolph" <email@hidden>
  • Date: Fri, 4 May 2001 16:01:37 -0700

Open the MainMenu.nib file in your project. This will launch the interface builder application.
Select the "Classes" tab in the nib file document window (should be at the lower left of the display)

Click on NSObject, and hit return. Change the name "myObject" to whatever you want the name of your app delegate class to be.

Select Classes->Create Files... from IB's main menu.
Select Classes->Instantiate from the menu.

Now, control-drag a connection from "File's owner" to the instance you just created. In the connections inspector, double-click on the "delegate" outlet.

Back in the project builder, add whatever app delegate methods you want to the .m file you just created.

-jcr



On Friday, May 4, 2001, at 12:19 PM, Robert Lee Dotson wrote:

I've been seeing alot of posts telling people to send messages to the application delegate to do various things (services, windows, nib files, etc.) But I have no idea where in my apps code the delegate should be. When I launch my app, I want a set number of things to happen, but most of them *before* the main nib file loads (eg. polling for modems, open network connections, etc.) so the app can terminate or open another. How do I set the order in which objects are instantiated and/or nib files are loaded. Everything I read says 'send a message to the application delegate.
' But, as forementioned, I don't know how to do this. help!

-- Rob

"I'm not going to have some reporters pawing through our papers. We are the president." --Hillary Clinton
_______________________________________________
cocoa-dev mailing list
email@hidden
http://www.lists.apple.com/mailman/listinfo/cocoa-dev


"These kids today don't know the simple joy of saving four bytes of page-0 memory on a 6502" - unknown


References: 
 >NSApplication delegate (From: Robert Lee Dotson <email@hidden>)

  • Prev by Date: Re: NSApplication delegate
  • Next by Date: NSTextView without NSScrollView?
  • Previous by thread: Re: NSApplication delegate
  • Next by thread: NSTextView without NSScrollView?
  • Index(es):
    • Date
    • Thread