AnsweredAssumed Answered

Callouts appear at 0,0

Question asked by criver on Aug 27, 2012
Latest reply on Aug 27, 2012 by criver
Hi,

I'm trying to programmatically display a callout based on and AGSGraphic object selected in a table view (i.e.

// initial map / layer setup AGSTiledMapServiceLayer *tiledLayer = [AGSTiledMapServiceLayer tiledMapServiceLayerWithURL:[NSURL URLWithString:@MAP_SERVER]]; AGSEnvelope *env = [[AGSEnvelope alloc]                         initWithXmin:INITIAL_XMIN                         ymin:INITIAL_YMIN                         xmax:INITIAL_XMAX                         ymax:INITIAL_YMAX                         spatialReference:[AGSSpatialReference spatialReferenceWithWKID:102100]];      [self.mapView addMapLayer:tiledLayer withName:@"Tiled Layer"]; [self.mapView zoomToEnvelope:env animated:NO]; [self.mapView setCalloutDelegate:self];   // user taps on search result  AGSGraphic *g = [self.featureSet.features objectAtIndex:indexPath.row]; [self.mapView showCalloutAtPoint:nil forGraphic:g animated:NO];


)

This always results in the callout displaying at x:0, y:0.

After searching the forums (and google) I have made sure that my spatialReferences line up, but it doesn't make any difference.  Is there something obvious I am missing?

Thanks for any help.

Chris

Outcomes