Simple question here. I have a UIButton, currencySelector, and I want to programmatically change the text. Here\'s what I have:
currencySelector.text = \"foo
In Swift 3, 4, 5:
button.setTitle("Button Title", for: .normal)
Otherwise:
button.setTitle("Button Title", forState: UIControlState.Normal)
Also an @IBOutlet has to declared for the button.
@IBOutlet
button