Search code examples
uibuttonswift2xcode7ibactionxcode-storyboard

How do I add border to an @IBAction Button that is linked from storyboard in Swift 2.1?


How to set button border if the button is linked to storyboard and is of type @IBAction?


Solution

  • The button's type is not IBAction, the IBAction is the connection between the storyboard and the function

    if you want to change the button in the code, connect it from the storyboard as an outlet (hold ctrl and drag the button from storyboard to your viewController)

    (and u can also change it from the storyboard)