In swift, I am trying to make a text field that will allow a button to be enabled, but only when the text field contains an integer. How can I do this?
Each text field has a keyboardType. You could set this to UIKeyboardType.NumbersAndPunctuation to only show numbers and still have the return key present (defensive UI). You could then use NSScanner's scanInt() to check if textField.text is a valid integer.