我在 UIAlertView 中有 UITextField。
当我将 6 个字符复制并粘贴到警报视图文本字段中时,它可以正常工作,但是当我粘贴超过 6 个字符时,它就不起作用了。
我该如何解决这个问题?
-(IBAction)btnForgotPasswordHandler:(id)sender{
cancelbtnPressed = NO;
self.alert=[[UIAlertView alloc]initWithTitle:@"Skribbee" message:@"Please input your email address to proceed!" delegate:self cancelButtonTitle:@"OK" otherButtonTitles:@"Cancel", nil];
[self.alert setAlertViewStyle:UIAlertViewStylePlainTextInput];
tfLostPassword=[alert textFieldAtIndex:0];
tfLostPassword.delegate = self;
[tfLostPassword setKeyboardType:UIKeyboardTypeEmailAddress];
[tfLostPassword setPlaceholder:@"Email Address"];
tfLostPassword.returnKeyType = UIReturnKeyGo;
[self.alert show];
}