WatchKit error - unable to find interface controller class '' to instantiate
For anyone else who has this. The class must be set to the correct target membership ie yourApp WatchKit Extension
rather than yourApp WatchKit App
when creating your class. It can also be edited in Target membership in interface builder.
Unable to find interface controller class 'InterfaceController' to instantiate
I've found the error! It was because of my .m file, it's target membership was MemGame
instead of MenGame WatchKit Extension
. So I uncheck the first option and selected the third option and now it's running perfectly.
Apple Watch notification issue: WatchKit error - unable to find interface controller class to instantiate
Two things to recheck,
- When you have created a new subclass of WKUserNotificationInterfaceController, Have you selected Watchkit extension as a target instead of iOS app target? You can verify this by Select Project > Select Watchkit Extension Target > Build Phases > Compile Sources. Here you should see NotificationInterface.m file created earlier. If you can't see then you have selected wrong target when creating a file. Then solution is you can create a new class with correct target selected.
- In Storyboard, make sure custom class name is correctly added. Also in Payload file, category name should match with category set to storyboard scene just to avoid future errors.
interface does not define view controller class
The view controller is missing the identifier in the storyboard
reference interfacecontroller in swift, watchkit
You can use the rootInterfaceController property on WKExtension:
WKExtension.sharedExtension().rootInterfaceController
Related Topics
Swift 3: How to Add Watermark on Video? Avvideocompositioncoreanimationtool iOS 10 Issue
How to Dynamically Format a Number to Have Commas in a Uitextfield Entry
Cllocationmanager Responsiveness
How to Use Uiviewcontrolleranimatedtransitioning with Uinavigationcontroller
Swift - Must Call a Designated Initializer of the Superclass Skspritenode Error
What Is the Impact of the "Requires Full Screen" Option in Xcode for an Iphone-Only App
Container View Getting Pushed Down as If It Had a Uinavigationbar
How Should a Swift + Objective-C Project Be Setup for Unit Testing
Change App Language in iOS Without Restarting the App
React-Native iOS Not Showing Images (Pods Issue)
Xcode 4.3:Missing Icons for iOS Apps in Organizer's Archives
Uitableview Not Visible the Last Cell When Scroll Down
Peripheral and Central at the Same Time on iOS
Get Tapped Word from Uitextview in Swift
Detect Which App Is Currently Running on iOS Using Sysctl
Ios: Avplayer - Getting a Snapshot of the Current Frame of a Video