title: Passing data to the view controller that UINavigationController points to
body: <p>So heres my question. I am a silent stackoverflow skimmer and Im using xcode 4.5 storyboards for an application which starts with a view controller which asks for the username and password. My application checks data via a backend server and then if the login is correct it performs a segue which points to the uinavigationcontroller which forwards the screen to the main menu.... The uinavigationcontroller hasnt been tampered with and pushes the mainmenu automatically.</p>
  
  <pre><code>Login_screen -&gt; UINavigationController -&gt; Main_Menu
  </code></pre>
  
  <p>My question is how do i pass the <code>NSString</code> username from the login screen to the main menu screen. </p>
  
  <p>I understand how to pass data from one screen to the next when the segue is pointing directly to it via the <code>prepareforsegue</code> method as well as <code>performsegue</code>. But in this case the <code>login_screen</code> segue points to the <code>uinaviationcontroller</code> which points to the <code>main_menu controller</code></p>
  
  <p>My assumption is that i will need to make a custom class which inherits <code>UINavigationController</code> and implement certain methods but since <code>uinavigationcontroller</code> isnt seen i dont think <code>viewdidload</code> or <code>viewwillappear</code> are the right methods.</p>
  
  <p>Any help will be appreciated</p>
  
  <p>I am a new user so i am not allowed to post images but i will fix that as soon as possible</p>