title: Objective-C iPhone - Open URL in Safari immediately and exit app
body: <p>I am able to open a URL in Safari using:</p>
  
  <pre><code>[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"www.myurl.com"]];
  </code></pre>
  
  <p>It works fine, but it takes more than 10 seconds in the Simulator.  I've tried putting this code inside the app delegate's <code>didFinishLauchingWithOptions</code> method or my view controller's <code>viewDidLoad</code> method, but it still takes over 10 seconds to load.  I get a black screen with nothing on it for that entire duration before it suddenly opens Safari.  Is there any way I could decrease the load time?  Is this only a Simulator bug??  I am still trying to get my devices registered to test on actual devices.</p>
  
  <p>The funny thing is that when I add it to a UIButton's action method, the app loads right away, but the user must tap the UIButton to launch the URL in Safari.</p>
  
  <p>My objective here is to have an app that upon startup, immediately launches a hard-coded URL in safari.  The app should immediately exit so that it will be able to do this again when the user taps on the app icon.  Any suggestions?</p>
  
  <p>Here's a snippet of what I attempted before in my ViewController.m that has the 10 second black screen if you want to try it yourself:</p>
  
  <pre><code>- (void)viewDidLoad
  {
      [super viewDidLoad];
      [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"www.myurl.com"]];
      exit(0);
  }
  </code></pre>