I want a user to know where they clicked last on a map.
I am looking for a way to add a point symbol and remove the old one when a map is clicked.
I am using this: Add graphics to a map | ArcGIS API for JavaScript sample.
I can add a point but I have to click on the add point button in the tool bar.
I am thinking Like this: SoilWeb: An Online Soil Survey Browser | California Soil Resource Lab but with Esri API not google.
Thank you
Solved! Go to Solution.
Here's a simple Fiddle showing you the essential code to do this. You just need to tie into the map's click event and then add your graphic in that event handler's function.
Steve
Here's a simple Fiddle showing you the essential code to do this. You just need to tie into the map's click event and then add your graphic in that event handler's function.
Steve
Steve,
Your fiddle does not seem to be working, I got to code you provided to work though!
Thank you!
Rickey,
That's weird. It works when I'm logged into JSFiddle but not when I'm logged out. Oh well. Glad the code helped you, though!