swiftuitextfielduitextfielddelegateuitextinput

Get Text Input WITHOUT UITextField Swift


I'm making an app and I want the user to be able to input text without having them actually click on a UITextField (have it open after the game ends for a scoreboard), is there some way to do that?


Solution

  • Call the following in the viewDidLoad of scoreboard, or whatever the entry point of that view is.

    yourTextField.becomeFirstResponder()