check wich which edit start UITextField up the view obj c code example
Example 1: xcode get info from text field
let text = myTextField.text
Example 2: xcode how to know which textfield is selected
class ViewController : UIViewController, UITextFieldDelegate {
var activeTextField = UITextField()
func textFieldDidBeginEditing(textField: UITextField) {
self.activeTextField = textField
}
func anotherMethod() {
if let activeTextFieldText = self.activeTextField.text {
print("Active text field's text: \(activeTextFieldText)")
return;
}
print("Active text field is empty")
}
}