As pheelicks said for UIButton
can create it with type UIButtonTypeCustom
.
For UITextField
set its border style to UITextBorderStyleNone
.
UIButton* button=[UIButton buttonWithType:UIButtonTypeRoundedRect];
UITextField* text1=[[UITextField alloc] initWithFrame:CGRectMake(120, 10, 200, 30)];
text1.borderStyle=UITextBorderStyleRoundedRect;