views:

44

answers:

1

Hi All,

Is there a way to hide UIAlertView programatically? Actually I have added a UITextField in UIAlertView and I want to perform the same operation as on "Ok" button press when a user hits the keyboard return key.

Thanks

Saurabh

+2  A: 

Call

[theAlertView dismissWithClickedButtonIndex:0 animated:YES];

when you handle the return key.

KennyTM
Thanks! Stackoverflow saying that you can accept answer in 9 mins.. I'll accept after 9 mins.. thanks again!
Saurabh