Ok, it's not as simple as it sounds...
I've got a uitextfield inside of a uitableviewcell and I want it to resign when the user off-taps.
I've tried the "background tap" method, but since the background is of the class UItableView it doesnt seem to register at all.
Is there a way I can detect the table scrolling? and use that to resignFirstResponder?
I'm pretty stumped by this. Even apple in their Contacts app doesnt resign the keyboard when the tableview in the background is tapped. Maybe it's not possible?
Any help is appreciated!
My current code:
Code:
-(IBAction)backgroundTap:(id)sender {
NSLog(@"background Tap");
[self.textFieldBeingEdited resignFirstResponder];
}
-(void)textFieldDidBeginEditing:(UITextField *)textField{
self.textFieldBeingEdited = textField;
}