How to trigger alert for multiple monitored regions?

Hi there,

I’m trying to figure out how to trigger different alerts for different monitored regions on the iphone. I know how to set up monitored regions and start monitoring…

    //Monitoring a Region
    CLLocationCoordinate2D layerCoords =
    CLLocationCoordinate2DMake(53.385909, -6.260067);
    CLRegion *layerRoom = [[CLRegion alloc]
    // Start monitoring for our CLRegion using best accuracy
    [locationManager startMonitoringForRegion:layerRoom

but I’m not quite sure how to set up different alerts for each region once they are entered. Currently, I’m using the didEnterRegion: method to trigger the alert but I only know how to do that once.

//Setting up alerts for when region is entered

  • (void)locationManager:(CLLocationManager *)manager didEnterRegion:(CLRegion *)region {

    UIAlertView *locationAlert = [[UIAlertView alloc]
    initWithTitle:@“Success!” message:@“You have arrived!” delegate:nil cancelButtonTitle:@“OK” otherButtonTitles:nil];

    [locationAlert show];


Can somebody help? I’m a total newbie. Thanks very much in advance!

Pure speculation, haven’t looked at the API at all, but judging by the fact that locationManager:didEnterRegion: takes a region as argument, you should be able to determine the region by examining that parameter and deciding what to do next.

Or am I overlooking something?