5

In the middle of my creating the app, xcode quit allowing me to ctrl-drag UIButtons to VCs for creating IBActions. This happens on every VC (nine in all). It does allow for creating Outlets, though. (Pls see image -> no Action selection is showing)

xcode Version 7.2 (7C68) build target is ios9.

Is there a way to fix this?

ctrl-drag in xcode does not bring up IBAction

sakumatto
  • 157
  • 1
  • 9

1 Answers1

1

Some things to try:

Make sure you are using one of the "Sent Events" to create the IBAction - not a Triggered Segue (that will do what you are describing) or other connection.

Try connecting not just via Ctr-drag, but via the right click menu or connections menu.

Try adding the code:

@IBAction func myAction()
{ }

... a clear circle should appear, which can be connected via dragging to the button in IB. This will create a Touch Up Inside event.

Finally, restart your project and try again.

DrWhat
  • 2,360
  • 5
  • 19
  • 33