ios - How to disable keyboard but enable UITextFields when using UIDatePicker? -


this 1 kind of hard explain, ask questions need clarify question. have ipad app (xcode 4.2, ios 6, arc , storyboards).

in app, have uipopover contains uiview 2 (2) uitextfields in , uidatepicker. (see image). when go scene, have unchecked userinteractionenabled on both textfields prevent keyboard responding, works, doesn't allow other uitextfield accessed after first one. tried [ofinishtime setinputview:otimepicker]; takes timepicker , moves outside of popover, unacceptable.

image showing 2 uiviews , datepicker

i have touchupinside events "wired" each of textfields, neither 1 gets called when tapped due userinteractionenabled being unchecked. remedy whole thing if have enabled , set flag in action event.

how can enable both uitextfields yet prevent keyboard showing? happy post relevant code need see.

may did not understand problem correctly , seems trying open picker on tap , display value set in uipicker. not using functionality of uitextfield. label or button might serve same purpose , save doing work of disabling keyboard.

in case if want use textfield , disable keyboard picker appearing input view , have own input view it, do

-(void)textfielddidbeginediting:(uitextfield *)textfield{     [textfield resignfirstresponder]; } 

you take @ this: display datepicker on tapping on textfield


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -