Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/113.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Objective c 关闭前的UIAlertView验证_Objective C_Ios_Uialertview - Fatal编程技术网

Objective c 关闭前的UIAlertView验证

Objective c 关闭前的UIAlertView验证,objective-c,ios,uialertview,Objective C,Ios,Uialertview,在关闭警报之前,是否有方法在UIAlertView中为textfield添加验证检查?例如,检查用户名和密码等用户凭据,如果其不正确,则更新UIAlertView中凭据不正确的文本。仅当验证检查通过时才关闭UIAlertView 谢谢 我想您可能希望使用子类来提供这种行为。在我看来,验证文本输入并保持UIAlertView打开是不可能的 或者,如果输入的密码不正确,您可以验证输入的文本并重新显示UIAlertView。无论如何,您应该避免在UIAlertViews中输入文本。该功能可能会更改,您

在关闭警报之前,是否有方法在UIAlertView中为textfield添加验证检查?例如,检查用户名和密码等用户凭据,如果其不正确,则更新UIAlertView中凭据不正确的文本。仅当验证检查通过时才关闭UIAlertView


谢谢

我想您可能希望使用子类来提供这种行为。在我看来,验证文本输入并保持UIAlertView打开是不可能的


或者,如果输入的密码不正确,您可以验证输入的文本并重新显示UIAlertView。

无论如何,您应该避免在
UIAlertView
s中输入文本。该功能可能会更改,您的应用程序可能会被拒绝。是否可以覆盖子类中的按钮单击处理程序,并重新绘制警报?您是如何解决此问题的?我有一些非常相似的东西,但我不太明白。