• 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
NSInvocation problem - "NSView not correctly initialized"
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSInvocation problem - "NSView not correctly initialized"


  • Subject: NSInvocation problem - "NSView not correctly initialized"
  • From: Gorazd Krosl <email@hidden>
  • Date: Mon, 5 Nov 2007 10:15:03 -0500 (EST)

Hi Robert,

As the message says: "NSView not correctly
initialized", you are only allocating the instance of
NSButton. ObjC requires an additional -init message to
be send to it for initialzation. NSButton expects
-initWithFrame: at least, to correctly initialize its
NSView superclass.

I am not at my computer right now, so I do not
remember NSButton's designated initializer, but for
NSView the sequence is:
NSView *myView = [[NSView alloc]
initWithFrame:someFrame];

HTH
Gorazd



      Ask a question on any topic and get answers from real people. Go to Yahoo! Answers and share what you know at http://ca.answers.yahoo.com
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: display a text field?
  • Next by Date: Re: Converting *u unicode hex sequences
  • Previous by thread: Re: NSInvocation problem - "NSView not correctly initialized"
  • Next by thread: is part of Bundle?
  • Index(es):
    • Date
    • Thread