开发者

Set the title of UIButton

how can I set the title of an UIButton开发者_如何学运维?


[button setTitle:@"Title" forState:UIControlStateNormal];

The same way you can set separate title if needed for highlighted and selected state (changing last parameter)


//PSEUDO CODE

UIButton *myButton;

[myButton setTitle: @"I'm a f%&%$$%&& button!!!!!!!! yay" forState:UIControlStateNormal];
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜