<?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 Why does extent-change fire 3 times when map is loading? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-does-extent-change-fire-3-times-when-map-is/m-p/722352#M67074</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;I'm using the Tax Parcel Viewer and am trying to get the initial extent to fall where I want it when the map loads.&amp;nbsp; To help me figure out what's going on I'm using the following listener:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var mapExtentChange = map.on("extent-change", changeHandler);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;function changeHandler(evt) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var extent = evt.extent,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; zoomed = evt.levelChange;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; alert('you moved');&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event fires 3 times while map is loading.&amp;nbsp; When I use previous extent button, I can see what the previous extents were and it makes no sense.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;How can I figure out what is making the extent-change fire three times when the map is initially loading?&lt;/STRONG&gt;&amp;nbsp; All this loading seems like a poor use of resources.&amp;nbsp; Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 01 Apr 2016 14:56:24 GMT</pubDate>
    <dc:creator>PLadd</dc:creator>
    <dc:date>2016-04-01T14:56:24Z</dc:date>
    <item>
      <title>Why does extent-change fire 3 times when map is loading?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-does-extent-change-fire-3-times-when-map-is/m-p/722352#M67074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;I'm using the Tax Parcel Viewer and am trying to get the initial extent to fall where I want it when the map loads.&amp;nbsp; To help me figure out what's going on I'm using the following listener:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var mapExtentChange = map.on("extent-change", changeHandler);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;function changeHandler(evt) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; var extent = evt.extent,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; zoomed = evt.levelChange;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; alert('you moved');&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This event fires 3 times while map is loading.&amp;nbsp; When I use previous extent button, I can see what the previous extents were and it makes no sense.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;How can I figure out what is making the extent-change fire three times when the map is initially loading?&lt;/STRONG&gt;&amp;nbsp; All this loading seems like a poor use of resources.&amp;nbsp; Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Apr 2016 14:56:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-does-extent-change-fire-3-times-when-map-is/m-p/722352#M67074</guid>
      <dc:creator>PLadd</dc:creator>
      <dc:date>2016-04-01T14:56:24Z</dc:date>
    </item>
    <item>
      <title>Re: Why does extent-change fire 3 times when map is loading?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-does-extent-change-fire-3-times-when-map-is/m-p/722353#M67075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Patrick,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Have you looked in the code for anything that is setting the maps extent like map.setExtent(xyz); You may have better luck posting an issue to the gitHub repo for this template. That way one of the template developer can respond.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:51:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/why-does-extent-change-fire-3-times-when-map-is/m-p/722353#M67075</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2016-04-06T13:51:39Z</dc:date>
    </item>
  </channel>
</rss>

