[英]iOS Dismiss Alert Open Textfield
Is there a way in iOS to open up the textfield (Like the user clicked on it (bringing up the keyboard)) after they dismiss an alert? 解除警报后,iOS中有没有办法打开文本字段(就像用户单击它一样(调出键盘))? Don't have any code to show because I have no idea where to start!
没有任何代码可显示,因为我不知道从哪里开始! :)
:)
Implement UIAlertViewDelegate
method. 实现
UIAlertViewDelegate
方法。
On clickedButtonAtIndex:
method ,put the code to show the textfield, by changing hidden
property or addSubview:
在
clickedButtonAtIndex:
方法上,通过更改hidden
属性或addSubview:
,使代码显示文本字段addSubview:
and to bring up the keyboard 并调出键盘
[textField becomeFirstResponder];
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.