AnsweredAssumed Answered

Zoom inside the loaded Dynamic Map when Location Service is OFF

Question asked by gajanaik on Jul 7, 2015
Latest reply on Jul 8, 2015 by gajanaik

I have dynamic MAP loaded on Blank Map or Tiled MAP.

i need to Zoom in to Dynamic MAP when Location Service is OFF or when dynamic MAP looks like small dot on Blank Map.

 

have added below code from Esri sample code... but this will not zoom inside Loaded Dynamic MAP.. but will show as small dot... then need to zoom in manually TAP gesture/ touch ....

 

    AGSSpatialReference *spatialReference = [AGSSpatialReference wgs84SpatialReference];

  //zoom to dynamic layer

  AGSEnvelope *envelope = [AGSEnvelope envelopeWithXmin:-178.217598362366 ymin:18.9247817993164 xmax:-66.9692710360024 ymax:71.4062353532712 spatialReference:spatialReference];

 

    AGSGeometryEngine *geometryEngine = [AGSGeometryEngine defaultGeometryEngine];

    AGSEnvelope * webMercatorEnvelope = (AGSEnvelope*) [geometryEngine projectGeometry:envelope toSpatialReference:self.mapView.spatialReference];

 

  [self.mapView zoomToEnvelope:webMercatorEnvelope animated:YES];

 

i need to zoom inside dynamic MAP....when it is loaded...

Outcomes