Hello,
I have a simple map containing a Tiled Layer, and a cashed layer. When I add a Graphic Point, it will only display if I do not load the Tiled Service.
Here is the code:
var streetsCacheLayer = new ArcGISTiledMapServiceLayer(new Uri(streetsCacheUrl));
streetsCacheLayer.MaxScale = 36111;
var streetsDynamicLayer = new ArcGISDynamicMapServiceLayer(new Uri(streetsDynamicUrl));
var graphicsLayer = new Esri.ArcGISRuntime.Layers.GraphicsLayer();
graphicsLayer.ID = "MyGraphics";
var mapPoint = new MapPoint(-76.644759, 39.516597);
var depotSym = new SimpleMarkerSymbol { Style = SimpleMarkerStyle.Circle, Size = 16, Color = Colors.Green };
var depotMapGraphic = new Graphic { Geometry = mapPoint, Symbol = depotSym };
graphicsLayer.Graphics.Add(depotMapGraphic);
await streetsCacheLayer.InitializeAsync();
await streetsDynamicLayer.InitializeAsync();
await graphicsLayer.InitializeAsync();
// If I comment out the next line the graphic shows up, otherwise it does not.
MyMap.Layers.Add(streetsCacheLayer);
MyMap.Layers.Add(streetsDynamicLayer);
MyMap.Layers.Add(graphicsLayer);
Any ideas?
Thanks,
Ed
Hi,
My guess is that the tile layer is in different SpatialReference. Can you make sure that you use the same SR for the graphic too.