In interface builder there is available type of object called “Object”.
I have tried to use this to wire up a view with a property pointing to one of these objects.
I have set the class on Object in interface builder to a custom class. I don’t need to set any other properties on this custom class. Basically my desired behaviour is that if that property is set then the view will call a method on it during its lifecycle.
When the view is inflated from the nib file however, my property on the view remains nil.
Is what I am trying to do possible?
I think that:
@property (nonatomic, retain) IBOutlet MyClass *anObj;and synthesized it in *.m file; AND+allocand-initof your custom class in astrange way (IB objects get instantiated via alloc and init calls AFAIK – someone please correct me if I’m wrong)
your object should not be
nilafter the nib file was unarchived in runtime. If I meet above conditions for my objects in IB, they are notnil.