O oxcug macrumors newbie Original poster Apr 13, 2012 #1 Hey guys how do I add a label to a UIView (separate from the view controller)? And how would I do it for a UIScrollView? Of course this is all via code. Last edited: Apr 13, 2012
Hey guys how do I add a label to a UIView (separate from the view controller)? And how would I do it for a UIScrollView? Of course this is all via code.
jnoxx macrumors 65816 Apr 14, 2012 #2 Code: UILabel *label1 = [[UILabel alloc] initWithFrame:CGRectMake(1,1,40,40)]; label1.text =@"BAWSE"; [self.scrollview addSubview:label1]; Something like that, did it out of the head. It's not that hard..
Code: UILabel *label1 = [[UILabel alloc] initWithFrame:CGRectMake(1,1,40,40)]; label1.text =@"BAWSE"; [self.scrollview addSubview:label1]; Something like that, did it out of the head. It's not that hard..
O oxcug macrumors newbie Original poster Apr 14, 2012 #3 jnoxx said: Code: UILabel *label1 = [[UILabel alloc] initWithFrame:CGRectMake(1,1,40,40)]; label1.text =@"BAWSE"; [self.scrollview addSubview:label1]; Something like that, did it out of the head. It's not that hard.. Click to expand... Yeah that's what I ended up doing Thanks very much!
jnoxx said: Code: UILabel *label1 = [[UILabel alloc] initWithFrame:CGRectMake(1,1,40,40)]; label1.text =@"BAWSE"; [self.scrollview addSubview:label1]; Something like that, did it out of the head. It's not that hard.. Click to expand... Yeah that's what I ended up doing Thanks very much!