-2

I can right click and drag so it automatically adds an IBOutlet successfully but only in the first view controller. I can right click and drag but it will not add an iboutlet. How do i fix this?

1 Answers1

0

You can just add @IBOutlet if the class you are trying to add it is a custom class of your controller.

In your case looks like firstViewController is the custom class of your view, what means that secondViewController cannot be.

enter image description here

In this example I can only add @IBOutlet to my LoginViewController, if I try to add in other classes XCode won't let me.

Icaro
  • 14,585
  • 6
  • 60
  • 75