I am using Xcode 7.3.1and when I try to connect the table view or the bar button item (Add) I cannot do so.
From past experience I believe that this is due to the fact that a view class has not been set. I have gone over the tutorial very closely and get the same result.
Any help will be appreciated.
When I set the table view controller to Class: ViewController I get the following error:
âLaunch screens may not set custom classnamesâ
Update:
If I click on the nav controller the Identity Inspector has âUINavigationControllerâ grayed out in the Class pane. Doing the same on the View Controller, the Class pane shows âUIViewControllerâ grayed out. So it appears that all is well in that regard.
So why canât I connect the objects to the viewController.swift file?
Another clue:
When I run the app on my iPhone the View Controller does not appear as it should. IOWâs the Add button does not appear.
Just a thought - but are you sure you are modifying Main.storyboard there? I seem to remember a similar error when I accidentally started building storyboard stuff in LaunchScreen.storyboard. Itâs an easy mistake to make as you scan down the project files and see âstoryboardâ and of course the interface looks basically the same.
@aeberbach
Could you kindly give me a swift kick in the a$$??
You are absolutely correct - I was working with the LaunchScreen.storyboard and not the Main.storyboard. Iâm wondering if I can staple a Post-It sticker to my forehead?? That is such a foolhardy schoolboy mistake.
That said, I cannot thank you enough for providing the correct solution to my blunder. Please donât tell anyone. Ha!
Thanks for taking your time to set me straight.
Well, I wish I could claim never to have made this mistake myselfâŠ
Donât worry. I wonât tell anyone. LOL!
Take care.