views:

575

answers:

1

Hello,

How to programmatically add UITextField on UIView in iPhone programming?

UITextField* text; UIView* view = [[UIView alloc]init];

[view addSubview:??????];

Thanks in Advance

+2  A: 
// setup some frames
UITextField* text = [[UITextField alloc] initWithFrame:frame]; 
UIView* view = [[UIView alloc] initWithFrame:frame];

[view addSubview:text];
Skie