Reputation: 2633
I have a uitextfield which is programatically added to view. I need to show a UIPickerview, when i tap on that, I have added a UITapgestureRecognizer for that and user interaction also enabled. Which was working fine till IOS 7.0. But when i updated to IOS 7.1 which is not getting called.
Upvotes: 2
Views: 1188
Reputation: 4513
Rather than setting a tap gesture for your textField
, you can simply set the inputView
of your textField
as your pickerView
. This simply enables you to show the UIPicker when the textField is tapped or gains focus. Something like:
[YOUR_TEXTFIELD setInputView:YOUR_PICKER_VIEW];
This is just an alternative solution to your issue. You can give it a try.
Upvotes: 1