je dois apparaître alerte quand mon application chargée ... Je l'ai appelé didfinished lancement .. après avoir cliqué sur le bouton ok besoin pour afficher un autre message d'alerte-je utiliser clickedButtonAtIndex ...qui UIAlertView a été Detecting cliqué
maintenant quand j'ai cliqué sur le bouton ok son appel encore et encore .. le alertview ..
Je dois appeler une seule fois ... que faire?
-(BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
// Override point for customization after application launch.
// Add the tab bar controller's view to the window and display.
[window addSubview:tabBarController.view];
[window makeKeyAndVisible];
viewControllersList = [[NSMutableArray alloc] init];
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Alert" message:@"Alow this app to use your GPS location"
delegate:self cancelButtonTitle:@"No" otherButtonTitles:@"Yes", nil];
[alert show];
[alert release];
}
- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex{
if (buttonIndex==0) {
NSLog(@"NO");
}
else {
NSLog(@"Yes");
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Alert" message:@"Do you want's to receive Push messages."
delegate:self cancelButtonTitle:@"No" otherButtonTitles:@"Yes", nil];
[alert show];
[alert release];
}
}
@thanks à l'avance.
délégué ensemble: néant en deuxième alertView – Saawan
@ merci ranjeet.sajwan –
k accueillir toujours ........ – Saawan