public void AddMarkerGraphics() { ESRI.ArcGIS.Client.Projection.WebMercator mercator = new ESRI.ArcGIS.Client.Projection.WebMercator(); GraphicsLayer graphicsLayer = myMap.Layers["MyGraphicsLayer"] as GraphicsLayer; Graphic graphic = new Graphic() { Geometry = mercator.FromGeographic(new MapPoint(115.257113, 33.0696150000001)), Symbol = LayoutRoot.Resources["DefaultMarkerSymbol"] as Symbol }; graphicsLayer.Graphics.Add(graphic); }
这个主要是FromGeographic()方法,传入的是一个4326的坐标系。