• 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: IB not recognising custom view
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: IB not recognising custom view


  • Subject: Re: IB not recognising custom view
  • From: Tommy Nordgren <email@hidden>
  • Date: Thu, 16 Oct 2008 02:24:53 +0200


On Oct 16, 2008, at 2:04 AM, DKJ wrote:

I created MyView as a subclass of NSView. I then compiled it into a static library. I referenced both libMyView.a and MyView.h in a project. In IB I put a custom view into the main window for that project, and set its class to MyView.

There's no problem building. But when I run it, I get this error:

	Unknown class 'MyView' in nib file, using '(null)' instead.

What's wrong here?

dkj
Xcode only links the object files from your library that is explicitly referenced from your code.
If you don't call a method in your class from your project source it won't be linked.
One Solution : first in main do [MyView initialize];


----------------------------------
The three things an undertaker should never say to a client:
-Nice doing business with you.
-Welcome back.
-Have a nice day. (The King of ID)
----------------------------------
Tommy Nordgren
email@hidden



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


References: 
 >IB not recognising custom view (From: DKJ <email@hidden>)

  • Prev by Date: Re: IB not recognising custom view
  • Next by Date: Re: Refactoring does not work
  • Previous by thread: Re: IB not recognising custom view
  • Next by thread: Newbie Question0 Renaming Classes
  • Index(es):
    • Date
    • Thread