<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Why Address is showing as undefined? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611377#M57179</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;A _jive_internal="true" data-userid="87605" data-username="manjarigoyal" href="https://community.esri.com/people/manjarigoyal" style="color: #3778c7; background-color: #ffffff; border: 0px; font-weight: 600; text-decoration: underline; font-size: 13.7136px;"&gt;Manjari Goyal&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would suggest to open your browser developer tool to see what type of network traffic returns when you click on the map.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ideally, you should be able to test with this reversegeocoding sample using JS 3.20:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/javascript/3/samples/locator_reverse/" title="https://developers.arcgis.com/javascript/3/samples/locator_reverse/"&gt;Find Address&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once you open the chrome developer tool and you will see the network traffic when you click on the map. The query request will send to&amp;nbsp;&lt;A class="link-titled" href="https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode" title="https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode"&gt;https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode&lt;/A&gt;&amp;nbsp;and if the&amp;nbsp;address is not existing in this geocode service you will probably see &amp;nbsp;the error message like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/350578_pastedImage_1.png" style="width: 620px; height: 230px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The reason why some address is not return is due to the fact of the geocode coverage, for more information please check this online documentation:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/rest/geocode/api-reference/geocode-coverage.htm" title="https://developers.arcgis.com/rest/geocode/api-reference/geocode-coverage.htm"&gt;Geocode coverage—ArcGIS REST API: World Geocoding Service | ArcGIS for Developers&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you need specific address for your interest that not exist in our "World Geocoding Service", the best option is creating your own geocode service. More information please check:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="http://server.arcgis.com/en/server/latest/publish-services/linux/geocode-services.htm" title="http://server.arcgis.com/en/server/latest/publish-services/linux/geocode-services.htm"&gt;Geocode services—Documentation | ArcGIS Enterprise&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this can help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 10 May 2017 21:35:38 GMT</pubDate>
    <dc:creator>YueWu1</dc:creator>
    <dc:date>2017-05-10T21:35:38Z</dc:date>
    <item>
      <title>Why Address is showing as undefined?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611376#M57178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to click on map and get lat, long and address in one popup window, but its not getting the address. Attached is the screenshot. Any help is appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var locator = new Locator("&lt;A href="https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer"&gt;https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer&lt;/A&gt;");&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var infoTemplate = new InfoTemplate("Location", "Address: ${Address}&amp;lt;br/&amp;gt;" +&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;"City: ${City}&amp;lt;br/&amp;gt;" +&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;"State: ${Region}&amp;lt;br/&amp;gt;");&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var symbol = new SimpleMarkerSymbol().setStyle(&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;SimpleMarkerSymbol.STYLE_CIRCLE).setColor(&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;new Color([0,0,255,0.5])&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;locator.on("location-to-address-complete", function(evt) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.graphics.clear();&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;console.log(evt);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (evt.address.address) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var address = evt.address.address;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var location = webMercatorUtils.geographicToWebMercator(evt.address.location);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var graphic = new Graphic(location, symbol, address, infoTemplate);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.graphics.add(graphic);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var screenPnt = map.toScreen(location);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.infoWindow.resize(300,100);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&amp;nbsp;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;});&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.on("click", function(evt) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.infoWindow.setTitle("Coordinates/Address");&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.infoWindow.setContent("lat/lon : " + evt.mapPoint.y.toFixed(3) + ", " + evt.mapPoint.x.toFixed(3) + "&amp;lt;br&amp;gt;Address: " + evt.mapPoint.address);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.infoWindow.show(evt.screenPoint,map.getInfoWindowAnchor(evt.screenPoint));&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;});&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 May 2017 20:37:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611376#M57178</guid>
      <dc:creator>ManjariGoyal</dc:creator>
      <dc:date>2017-05-10T20:37:18Z</dc:date>
    </item>
    <item>
      <title>Re: Why Address is showing as undefined?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611377#M57179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;A _jive_internal="true" data-userid="87605" data-username="manjarigoyal" href="https://community.esri.com/people/manjarigoyal" style="color: #3778c7; background-color: #ffffff; border: 0px; font-weight: 600; text-decoration: underline; font-size: 13.7136px;"&gt;Manjari Goyal&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would suggest to open your browser developer tool to see what type of network traffic returns when you click on the map.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ideally, you should be able to test with this reversegeocoding sample using JS 3.20:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/javascript/3/samples/locator_reverse/" title="https://developers.arcgis.com/javascript/3/samples/locator_reverse/"&gt;Find Address&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once you open the chrome developer tool and you will see the network traffic when you click on the map. The query request will send to&amp;nbsp;&lt;A class="link-titled" href="https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode" title="https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode"&gt;https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer/reverseGeocode&lt;/A&gt;&amp;nbsp;and if the&amp;nbsp;address is not existing in this geocode service you will probably see &amp;nbsp;the error message like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/350578_pastedImage_1.png" style="width: 620px; height: 230px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The reason why some address is not return is due to the fact of the geocode coverage, for more information please check this online documentation:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/rest/geocode/api-reference/geocode-coverage.htm" title="https://developers.arcgis.com/rest/geocode/api-reference/geocode-coverage.htm"&gt;Geocode coverage—ArcGIS REST API: World Geocoding Service | ArcGIS for Developers&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you need specific address for your interest that not exist in our "World Geocoding Service", the best option is creating your own geocode service. More information please check:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="http://server.arcgis.com/en/server/latest/publish-services/linux/geocode-services.htm" title="http://server.arcgis.com/en/server/latest/publish-services/linux/geocode-services.htm"&gt;Geocode services—Documentation | ArcGIS Enterprise&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this can help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 May 2017 21:35:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611377#M57179</guid>
      <dc:creator>YueWu1</dc:creator>
      <dc:date>2017-05-10T21:35:38Z</dc:date>
    </item>
    <item>
      <title>Re: Why Address is showing as undefined?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611378#M57180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yue Wu,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have already looked in to this and the problem is I write two independent script one for geocode the address and other for reverse geocode it works fine but when I tried to create one script where I can get both the address and lat long and it doesn't work. below is the screenshot which I am trying to create in javascript 3.12&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 May 2017 21:48:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611378#M57180</guid>
      <dc:creator>ManjariGoyal</dc:creator>
      <dc:date>2017-05-10T21:48:08Z</dc:date>
    </item>
    <item>
      <title>Re: Why Address is showing as undefined?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611379#M57181</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;I have found the solution below is the code in which you can see the address and XY in the same popup window.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// Set up a locator task using the world geocoding service &lt;BR /&gt;&lt;SPAN&gt; var locator = new Locator("&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fgeocode.arcgis.com%2Farcgis%2Frest%2Fservices%2FWorld%2FGeocodeServer" rel="nofollow" target="_blank"&gt;https://geocode.arcgis.com/arcgis/rest/services/World/GeocodeServer&lt;/A&gt;&lt;SPAN&gt;");&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;map.on("click", function(evt) {&lt;BR /&gt; locator.locationToAddress(evt.mapPoint, 100);&lt;BR /&gt; });&lt;/P&gt;&lt;P&gt;locator.on('location-to-address-complete', function(evt) {&lt;BR /&gt; console.log(evt);&lt;BR /&gt; var location = webMercatorUtils.geographicToWebMercator(evt.address.location)&lt;BR /&gt; var screenPoint = map.toScreen(location);&lt;BR /&gt; console.log(screenPoint);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;// dig out the best attribute from matched address to display in popup&lt;BR /&gt; map.infoWindow.setTitle("Coordinates/Address");&lt;BR /&gt; map.infoWindow.setContent("Latitude: " + evt.address.location.x.toFixed(3) + "&amp;lt;br&amp;gt;Longitude: " + evt.address.location.y.toFixed(3) + "&amp;lt;br&amp;gt; Address: " + evt.address.address.LongLabel);&lt;BR /&gt; map.infoWindow.show(screenPoint);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;// add an if/else and use the map click xy that you saved from the other event listener if no address was found&lt;BR /&gt; })&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Jul 2017 16:02:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-address-is-showing-as-undefined/m-p/611379#M57181</guid>
      <dc:creator>ManjariGoyal</dc:creator>
      <dc:date>2017-07-21T16:02:30Z</dc:date>
    </item>
  </channel>
</rss>

