Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error: unreachable because it has no entry points

Tags:

ios

swift

Using Swift I got the error that my "TableViewController" is unreachable because it has no entry points and no runtime access via [UIStoryboard instantiateViewControllerWithIdentifier].

In my View Controller class there is the suggestion to fix it while changing instantiateViewController(withIdentfier...) in instantiateViewController(withIdentifier).

Shall I do this or how do I fix this?

like image 985
Philipp Koopmans Avatar asked Oct 04 '16 08:10

Philipp Koopmans


2 Answers

You need to mark a viewController in your Storyboard and set it to the initial viewController. You do this under the Attributes Inspector. This means that you set which viewController shall open when you start your application.

enter image description here

like image 184
Rashwan L Avatar answered Nov 19 '22 21:11

Rashwan L


I'd reached the same error. This answer would be useful, I think: Xcode: "Scene is unreachable due to lack of entry points" but can't find it

The problem was that because of some experiments and copy-pasting I had an actual copy of a view controller located outside the visible part of the screen or it could be stacked exactly on top of its twin. So I just deleted unwanted one :-) You should open Document Outline and сheck for copies :-)

Document Outline is showing 2 the same ViewControllers

like image 14
Vitya Shurapov Avatar answered Nov 19 '22 19:11

Vitya Shurapov