skip to Main Content

I have an app where I just created a new, working viewController in a separate project.
I copy/pasted the code and xibs (several subviews) into the new project. All compiles fine.
Relevant code:

let storyBoard : UIStoryboard = UIStoryboard(name: "Main", bundle:nil)
//let nextViewController = storyBoard.instantiateViewController(withIdentifier: "NewManualGlyphVC") as! NewManualPickGlyphViewController //old Selector
let nextViewController = storyBoard.instantiateViewController(withIdentifier: "GlyphSelectVC") as! GlyphSelectViewController //new Selector
self.navigationController?.pushViewController(nextViewController, animated: true)

The commented out line was the vector to the old, working VC. The new code crashes inside the push. the new nextViewController is fine, the Xcode quick view shows the expected view, and the navController is also just fine. The reported error is:

myApp[42661:963870] -[NSNull set]: unrecognized selector sent to instance 0x7ff86599bc30

Environment is Xcode 14.3.1 compiled to iOS 13, target device iOS 16.
Any thoughts?

2

Answers


  1. Maybe you should check the outlet of the presented VC

    Login or Signup to reply.
  2. In this case as my experience, please check on file view controller.swift and view controller.xib you push, make sure each variable @IBOutlet has reference reacher other between .xib file and .swift file or you check in xcode what line it error and fix find issue followed the line in xcode

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search