title: Programmatically generated buttons can't be pressed when the app is restarted
body: <p>I have programmatically generated a series of buttons in my app, and they work perfectly when they are pressed. Then I stored in memory the number of the buttons and, when I restart the app, the buttons are regenerated exactly as they were before, and yet they can't be pressed.
  The method "deletebtn" prints "pressed" when the button is pressed, but it doesn't.
  I've even tried to add to the properties of the programmatically generated button "buttonName.userInteractionEnabled = true", but nothing changes.</p>
  
  <p>This are the properties of the button, and that's also the code I have on the viewdidload, that recreates as much buttons as the number of them that I have stored in memory:</p>
  
  <pre><code>let btn: UIButton = UIButton(frame: CGRectMake(10, CGFloat(60*a), ScreenWidth - 20 , 50))    
  btn.layer.cornerRadius = 0.5 * btn.bounds.size.height
  btn.backgroundColor = UIColor.whiteColor()
  btn.setTitleColor(UIColor.blackColor(), forState: .Normal)
  btn.setTitle(ArrayService[(index)], forState: UIControlState.Normal)
  btn.addTarget(self, action: Selector("deletebtn:"), forControlEvents: UIControlEvents.TouchUpInside)
  btn.tag = a //an int variable that is increased each time i create a neew button
  btn.userInteractionEnabled = true
  self.ScrollPwd.addSubview(btn)
  </code></pre>
  
  <p>And here is the method deletebtn:</p>
  
  <pre><code>func deletebtn(sender:UIButton){
          print("pressed")
  }
  </code></pre>
  
  <p>The scrollView is where I put my buttons. I've tried adding "ScrollPwd.userInteractionEnabled = true", and yet I can just scroll through the buttons, but I can't press them.</p>
  
  <p>Can you help me?</p>