title: Add action to UIBarButtonItem Swift
body: <p>Button is created in storyboard and I want to add an action. </p>
  
  <pre><code>self.cancel.action = NSSelectorFromString("cancel:")
  
  func cancel(sender: UIBarButtonItem) -&gt;() {
  }
  </code></pre>
  
  <p>This not working. Thanks</p>