Re: IB not recognising custom view
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