I have the following bit of code in my super viewDidLoad
section of my app:
if ( appCounter < 1 ) {
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Disclaimer", "")
message:NSLocalizedString(@"By agrreing to use this service, dont use while driving", "")
delegate:nil
cancelButtonTitle:@"I Agree to not use this while Driving"
otherButtonTitles: nil];
[alert show];
appCounter = appCounter+1;
}
basically, it should show a disclaimer when the app loads. but every time the user navigates away from the main screen, and then comes back to the main scene (its a multiple view app) the disclaimer pops up again.
i would have thought that the app counter would have stopped this, yet it still keeps popping up.
Could someone please point out where in my code i have gone wrong? and what i need to do to rectify this?
Thank you in advance.