0

Please find the Image which shows my project storyboard.

  • iOS version - 6.0 and above
  • Xcode version - 6.2
  • Problem -> After Login, I open slide menu and click Rewards and i navigate to "View Controller 2". Then, from "View Controller 2" i click "Menu" option but i do not navigate to "View Controller 1" instead i get an empty page which does not show anything. My "Push Controller Segue 1" is not working but "Push Controller Segue 2" is working. When click the button in Login Form i navigate to "View Controller 1" (i have written this programmatically).
  • Solution Required - How to navigate to "View Controller 1" when i click "Menu" in Table View Controller (sw_rear).

Any sort of information required from me please let me know.

Gurtej Singh
  • 3,244
  • 1
  • 14
  • 27
TheGaME
  • 443
  • 2
  • 8
  • 21
  • Are your segues custom segues (SWRevealViewControllerSeguePushController) or you are using standard push segues? Also, are the segues linked to each of the prototype cells?When you login, do you land on View Controller 1? Is it embedded in a Navigation controller? What are it's contents? Show the code for that view controller. Also, are you really developing for iOS 6 and earlier? or you mean 6 and greater? – Gurtej Singh Aug 29 '15 at 15:54
  • @GurtejSingh.. They are standard Push segues. Yes, They are linked to each prototype cells. Yes, When i login i land on View Controller 1. It is not embedded in a navigation controller. It's contents are just one Navigation Bar and one Bar Button Item. Sorry for the mistake, i meant 6 and greater. – TheGaME Aug 29 '15 at 16:28
  • Can you try with Custom Segues as shown in the examples? Also do you see nothing when you land on View Controller 1? Are the Navigation bar and bar button item created via code? Can you post the code? – Gurtej Singh Aug 29 '15 at 16:49
  • @GurtejSingh.. Ok. First of all I do not land in View Controller 1 that is the problem i am facing. I am not creating bar and bar buttons via code. I just dragged and dropped them from toolbox. Which code file you want everything or particular controller one? – TheGaME Aug 29 '15 at 16:55
  • @GurtejSingh.. I have used custom segues only with Segue class as "SWRevealViewControllerPushController". Since i am using iOS 6 and greater i am not getting "SWRevealViewController". – TheGaME Aug 29 '15 at 16:59
  • possible to share your code for me to look at? It will be easier to narrow down the problem that way. Or if it's possible to reproduce this In a sample project. Let me know. Thanks! – Gurtej Singh Aug 29 '15 at 17:18
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/88272/discussion-between-thegame-and-gurtej-singh). – TheGaME Aug 29 '15 at 17:22
  • I'm back in the chat room. Let's resume. Thanks. – Gurtej Singh Aug 29 '15 at 17:48

1 Answers1

1

So, as discussed, the problem is the Segue from the login view controller to the menu view controller, the only issue is that the type of the segue used to do this was a show detail segue, which needs to be a show segue instead, which embeds the destination view controller in a UINavigationController.

Your main menu class (using SWRevealViewController) is expecting a UINavigationViewController to perform it's segues, which it is not able to find since the destination class is not embedded in a Navigation View controller. Either change the segue to show or you can choose to embed your destination view controller in a UINavigationViewController, but I would recommend to do the former.

Just for your reference, here is an interesting read on the difference between the show and the show detail segues:

What are the differences between segues: "show", "show detail", "present modally", "present as popover"?

Hope this answers your question.

Community
  • 1
  • 1
Gurtej Singh
  • 3,244
  • 1
  • 14
  • 27