razmaimon

set graphic on a location(lat-lon)

Discussion created by razmaimon on Jan 19, 2014
Latest reply on Jan 22, 2014 by sgill-esristaff
Good day all,

I am a bit NOOB here....so sorry for the basic question here...

I took the HelloWorld sample and now i want to add a Red circle on a location using lat-lon, for example:
double locx = 32.062910;
double locy = 34.780891;
SimpleMarkerSymbol symbol new SimpleMarkerSymbol(Color.RED,25, SimpleMarkerSymbol.STYLE.CIRCLE)

i've added a GraphicsLayer to my MapView
and now i'm stuck...
If i try to add a new Graphic to my GraphicsLayer using my lat-lon the marker apears in the middle of the map.
I use :
new Graphic(new Point(locx, locy), symbol));


can someone explain how to set the graphic in the correct place?

also, in the sample main.xml layout file,
you set the attribute initExtent. what does it mean?!?!
(initExtent = "-19332033.11, -3516.27, -1720941.80, 11737211.28")

Thanks,
Raz

Outcomes