Reputation: 2742
I have a custom UIView
subclass. I am loading this through [[NSBundle mainBundle] loadNibNamed:@"" ...]
. I have linked all of my outlets properly in Interface Builder but in initWithCoder
, my UILabel
is 0x0.
Where can I have a method that will call when the IBOutlets
will finish initalizing so I can access my UILabel
and call setText
?
Upvotes: 1
Views: 867
Reputation: 2742
Wow, found the answer!
- (void)awakeFromNib
Thanks to all that answered anyway!
Upvotes: 0
Reputation: 3752
viewDidLoad, and don't forget to call super
- (void)viewDidLoad
{
[super viewDidLoad];
mylabel.text = @"yadayadayada";
}
Upvotes: 1