Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Jan 24, 2007, 11:26 PM   #1
DavidCar
macrumors 6502a
 
Join Date: Jan 2004
Why can't I initialize my custom class?

In this example I posted earlier:

"My Approach to printing NSTableView"

http://forums.macrumors.com/showthread.php?t=273153

I was never able to properly initialize my custom NSBox class. I used Interface Builder to declare an NSBox to belong to the custom class, and the other methods there are called correctly, but not the init or initWithFrame methods, so I had to use an inelegant way of doing it.

Any thoughts as to what I'm doing wrong?
DavidCar is offline   0 Reply With Quote
Old Jan 25, 2007, 12:50 AM   #2
kainjow
Moderator emeritus
 
kainjow's Avatar
 
Join Date: Jun 2000
Your NSBox subclass may be created via the initWithCoder: method.
kainjow is offline   0 Reply With Quote
Old Jan 25, 2007, 01:24 AM   #3
DavidCar
Thread Starter
macrumors 6502a
 
Join Date: Jan 2004
Quote:
Originally Posted by kainjow View Post
Your NSBox subclass may be created via the initWithCoder: method.
I just tested it, and you're correct. Problem solved.

Thanks for the suggestion.

DC
DavidCar is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
How do I reference a subview in a custom UIView class? moonman239 iPhone/iPad Programming 1 Nov 7, 2013 02:38 PM
Referencing a child class in a parent class, good or bad? SAIRUS iPhone/iPad Programming 11 Aug 28, 2013 12:59 PM
call custom objc class from python ruchi830 Mac Programming 1 Jan 14, 2013 09:33 PM
How to create property thats also a custom made class? tradingjam Mac Programming 4 Aug 12, 2012 04:51 PM
Difference between Public class and private class. zijianz iPhone/iPad Programming 4 Jun 29, 2012 10:29 PM

Forum Jump

All times are GMT -5. The time now is 07:48 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC