简体   繁体   中英

Can't set the Class or Module in Storyboard, Xcode 6.2

I just updated to Xcode 6.2, now when I create a new ViewController in Storyboard, I can't assign a Class, the Module field is empty. I can't set the Module to the current project, the menu is blank.

The class field doesn't code complete for any class in my project. If I set the class manually I get the error: Unknown class OneViewController in Interface Builder file.

Inspecting the source code of the storyboard file, I can see the that the module is not set for the new view controller. Like I said earlier I can't set this in Storyboard.

I notice also that the default ViewController class is assigned to the default ViewController, and works but, the Module also shows blank for this view.

I was getting the same error after updating to 6.2. The way I fixed it was creating a new Cocoa Touch class and copying the code from the one that wasn't working (in your case OneViewController) into that. I deleted the old class and assigned the new one to the View Controller in my storyboard. Error gone.

I had the same problem. If you use Xcode 6.2 from App Store, delete it and download version from developer portal. This solves my problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM