Chewie The Chorkie
Chewie The Chorkie

Reputation: 5234

"No @implementation found for the class" error in Storyboard in Swift

I'm trying to create in IBOutlet in Swift using my Storyboard and assistant editor, but I'm receiving a strange error I've never seen before. Looks Objective-C-ish.

I navigated to my ViewController's Save button in my Storyboard

storyboard list

Then I control-click dragged the Save UIButton to Xcode's assistant editor to make the IBOutlet. I get the error "Could not insert new outlet connection: No @implementation found for the class "ClassBVC". How do I avoid this error so I can make the outlet and an action?

IBOutlet error

I noticed when I click the button with the four squares before "Manual" and the < > buttons, I can go to "Counterparts" and there's a "ClassBVC" file with the same name, but with "(Interface)" next to it. It's not the file that I need though. Even when trying to create an outlet there, I get the same error.

Upvotes: 3

Views: 3249

Answers (3)

islam XDeveloper
islam XDeveloper

Reputation: 494

Try closing Xcode and opening it again.

Upvotes: 4

gabrielrf97
gabrielrf97

Reputation: 317

Creating one @IBOutlet directly in the view controller, and then creating the reference to the component in the Outlet Section in .storyboard worked for me. After that, I was able to drag the components normally to their respective view controller.

Upvotes: 2

pankaj nigam
pankaj nigam

Reputation: 401

I had same problem. rebuilding works for me.

Upvotes: 5

Related Questions