title: Objective C: How to present modal view controller from appdelegate?
body: <p>I am in the appdelegate of my application. How can I add a modal view controller in the "didfinishlaunching" method?</p>
  
  <p>I tried the following but did not work</p>
  
  <pre><code>SomeViewController *vc = [[SomeViewController alloc]init];
  [self.tabController.navigationController presentModalViewController:vc animated:NO]; 
  </code></pre>
  
  <p>EDIT:
  I changed my implementation to the following</p>
  
  <pre><code>self.tabController.selectedViewController 
  = [self.tabController.viewControllers objectAtIndex:0];
  SomeViewController *vc = [[SomeViewController alloc]init];
  [self.tabController.selectedViewController presentModalViewController:vc animated:NO];
  </code></pre>
  
  <p>I checked that the 'selected view controller' is not null... however I am still not able to get the output I needed. Is there anything I am missing?</p>