Initially I wanted to introduce a picker when choosing a UITableViewCell or a UILabel.
The best way is 1. Sub-Class UItextfield and set a picker its inputView 2. Make becomeFirstResponder in didSelectRowAtIndexPath text field
Input View attribute is to assign picker view to the responder before the package. This will not show up. Therefore, WarmUpTextField.inputView = picker
to take should be taken viewDidLoad ()
.
didSelectRowAtIndexPath
respondents as Tekstfild set what to expect before below the function code should work as you expect.
override function tableView (tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {if indexPath.section == 0 {NameTexField.becomeFirstResponder ()} else if indexPath.section == 1 {WarmUpTextField.becomeFirstResponder ()}}
No comments:
Post a Comment