Ejemplo n.º 1
0
 public void SetInitialExtent()
 {
     // Set the initial extent.
     Esri.ArcGISRuntime.Geometry.SpatialReference sr       = Esri.ArcGISRuntime.Geometry.SpatialReferences.Wgs84;
     Esri.ArcGISRuntime.Geometry.Envelope         envelope = new Esri.ArcGISRuntime.Geometry.Envelope(10, 40, 14, 43, sr);
     this.mapView.Map.InitialViewpoint = new Esri.ArcGISRuntime.Controls.Viewpoint(envelope);
 }
Ejemplo n.º 2
0
        private async Task setExtent(MapPoint point1, MapPoint point2)
        {
            SpatialReference mySpatialReference = Esri.ArcGISRuntime.Geometry.SpatialReferences.Wgs84;

            Esri.ArcGISRuntime.Geometry.Envelope myEnvelope = new Esri.ArcGISRuntime.Geometry.Envelope(point1.X, point1.Y, point2.X, point2.Y, mySpatialReference);
            MapPoint point = new MapPoint((point1.X + point2.X) / 2, (point1.Y + point2.Y) / 2);
            await MapView.SetViewpointCenterAsync(point);

            AcceptNavigation.Visibility = Visibility.Visible;
            RefuseNavigation.Visibility = Visibility.Visible;
        }
Ejemplo n.º 3
0
 public void SetInitialExtent()
 {
     // Set the initial extent.
     Esri.ArcGISRuntime.Geometry.SpatialReference sr = Esri.ArcGISRuntime.Geometry.SpatialReferences.Wgs84;
     Esri.ArcGISRuntime.Geometry.Envelope envelope = new Esri.ArcGISRuntime.Geometry.Envelope(10, 40, 14, 43, sr);
     this.mapView.Map.InitialViewpoint = new Esri.ArcGISRuntime.Controls.Viewpoint(envelope);
 }