title: Displaying an alert message only ONCE but to reappear again on app launch
body: <p>I'm trying to figure out a way to get a message to appear on one of my view controllers when that screen controller is selected (this view is NOT the first view on the app, so I can't do it at start-up).  I only want it to appear ONCE and not appear again when that view is re-selected; however, I want it to appear again if the app is restarted.</p>
  
  <p>So far, I am able to get it to appear once without any problem AND it won't pop up again while using the app, which is what I want as I am often going back into other views and returning.  The problem I am having, is when I start the app up again, I want the alert message to appear when I select the appropriate view, but because of the data stored in NSUserDefaults it won't appear.</p>
  
  <p>Any ideas?  This appears in ViewWillAppear:</p>
  
  <pre><code> NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
      NSString *alertshown = [defaults stringForKey:@"alertshown"]; {
          if (alertshown == nil) {
  
  UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"Press the Code button" message:@"Take a photo of this screen and show it to get your code" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
  
              [alertView show];
              [alertView release];
  
              [defaults setObject:@"alertwasdisplayed" forKey:@"alertshown"];
          }}
  </code></pre>