how can i hide the keypad from iphone simulator after its use ? in my app Ist textfield is for name , another one is for password and one button i want to hide the keypad whenever i clicked on button.
+2
A:
in button action routine write [yourTextField resignFirstResponder]. it will hide your keyboard.
Jim.
Jim
2010-05-05 11:55:29
+1
A:
There are 2 method to do it...
1> Implement
- (IBAction) doneButtonOnKeyboardPressed: (id)sender
{
}
Method on Textfield 's Did End On Exit Event
OR
In Textfield implement this delegate method
-(BOOL)textFieldShouldReturn:(UITextField *)theTextField {
[txtName resignFirstResponder];
return YES;
}
mihirpmehta
2010-05-05 11:55:29