I have a few waypoints of a South Dakota Trail from a Garmin device in the decimal format (43.42330, -103.48474). In ArcGIS Runtime Android SDK 100.x.x I am opening a basemap and trying to add a simple marker symbol of a red dot on it.
ArcGISMap map = new ArcGISMap(Basemap.Type.TOPOGRAPHIC, 43.42330, -103.48474, 16); // create an initial viewpoint with a point and scale Point point = new Point(44.96971, -103.77460, SpatialReferences.getWebMercator()); Viewpoint vp = new Viewpoint(point, 7500);
Which is displayed while the app get loaded fine. Now I want to add a Simple Marker using this code on top of the map.
SimpleMarkerSymbol symbol = new SimpleMarkerSymbol(SimpleMarkerSymbol.Style.CIRCLE, Color.RED, 12); //size 12, style of circle //add a new graphic with a new point geometry Point graphicPoint = new Point(43.42330, -103.48474, SpatialReferences.getWebMercator()); Graphic graphic = new Graphic(graphicPoint, symbol); graphicsOverlay.getGraphics().add(graphic);
Currently the red dot is off the Gulf of Guinea in West Africa. What am I doing wrong. I think my Map zoom and Point scale are out of proposition? How would I fix this point to show up in the right place?