tags:

views:

199

answers:

2

HI all,

I am having a 2 textFeild and 1 textview.

out of 2 textfeild,one textfield requires number to be filled in there. so for that i hv provided numeric keyboard. i m not able to dismiss numeric keyboard,since i cant c any option to hit the numeric keyboard dismiss.

is it possible to dismiss numeric keyboard ??

if yes than can anyone guide me through.

regards shishir

+2  A: 

You have 2 options: add a return keyboard in a numpad keyboard or catch the event of user select another textfield and dismiss the numpad there. Here is the link to add a return (done) button to a numpad keyboard. Done in numpad keyboard

vodkhang
For the record, adding buttons to the standard keyboards is completely unsupported and likely to break. All the implementations I've seen on the net fail in various cases, for example when moving between textfields with different styles, or on the iPad which uses a different keyboard completely.
Mike Weller
@vodkhangthis is ultimate tutoriaqls manhttp://www.neoos.ch/news/46-development/54-uikeyboardtypenumberpad-and-the-missing-return-key#idc-cover...thank for the post
shishir.bobby
uhm... interesting... although I never see it fail on my application yet. I will remember this. Thanks
vodkhang
but just one more questionas i already mentioned,i hv two textfeildsone contain numbers and the other one can contain characters.i implemented the code of urs..when hit numeric textfild, ,numeric keyboard rises with done button,button,butwhen i hit the other textfeild,the character keyboard arises,with done button of numeric keyboard still there////......wat should i do to remove thisrthanks a lot for the link again
shishir.bobby
Can you check if the - (void)keyboardWillShow:(NSNotification *)note { is called again. If it is, you have to remove the observer using:[[NSNotificationCenter defaultCenter] removeObserver:self]; at an appropriate place
vodkhang
willl try for sure..thanks
shishir.bobby
A: 

There is no button to dismiss the numeric keypad (although on the iPad you can do this). You will have to call [textfield resignFirstResponder] in code if you want to do this yourself.

Mike Weller
@Mikeipad doess have return button on numeric keypad???
shishir.bobby