<?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: Map Loading Progress Bar/Animation Javascript 4.x in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331427#M30632</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Even if you do not concern yourself with the missing helper function&amp;nbsp;&lt;SPAN style="background-color: #ffffff;"&gt;&lt;A href="https://developers.arcgis.com/javascript/3/jsapi/esri.dijit.util.busyindicator-amd.html"&gt;busyIndicator&lt;/A&gt;&lt;/SPAN&gt;&amp;nbsp;there is the fact that the 4.x API still does not have an event dispatched when the map/view is done drawing. Now if you want to loop though the views layerViews and watch the updating property then you can probably do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-FeatureLayerView.html#updating" title="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-FeatureLayerView.html#updating"&gt;FeatureLayerView | API Reference | ArcGIS API for JavaScript 4.2 | updating&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I do not have any code samples to demo this though.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 27 Jan 2017 18:03:02 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2017-01-27T18:03:02Z</dc:date>
    <item>
      <title>Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331425#M30630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am pretty new to JavaScript and am having trouble figuring out how to display a "loading" gif onscreen while map items are loading.&amp;nbsp; I have been able to figure out how to do it using the 3.x api but am stumped when trying to accomplish the same thing using the new arcgis-javavascript-4.2 version.&amp;nbsp; Any help is greatly appreciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 00:12:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331425#M30630</guid>
      <dc:creator>BobNichols</dc:creator>
      <dc:date>2017-01-27T00:12:20Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331426#M30631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The &lt;A href="https://developers.arcgis.com/javascript/3/jsapi/esri.dijit.util.busyindicator-amd.html"&gt;busyIndicator&lt;/A&gt; hasn't been added to 4.2 yet. &lt;A class="link-titled" href="https://developers.arcgis.com/javascript/latest/guide/functionality-matrix/index.html#widgets" title="https://developers.arcgis.com/javascript/latest/guide/functionality-matrix/index.html#widgets"&gt;Functionality matrix | ArcGIS API for JavaScript 4.2&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 17:48:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331426#M30631</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2017-01-27T17:48:25Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331427#M30632</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Even if you do not concern yourself with the missing helper function&amp;nbsp;&lt;SPAN style="background-color: #ffffff;"&gt;&lt;A href="https://developers.arcgis.com/javascript/3/jsapi/esri.dijit.util.busyindicator-amd.html"&gt;busyIndicator&lt;/A&gt;&lt;/SPAN&gt;&amp;nbsp;there is the fact that the 4.x API still does not have an event dispatched when the map/view is done drawing. Now if you want to loop though the views layerViews and watch the updating property then you can probably do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-FeatureLayerView.html#updating" title="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-layers-FeatureLayerView.html#updating"&gt;FeatureLayerView | API Reference | ArcGIS API for JavaScript 4.2 | updating&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I do not have any code samples to demo this though.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 18:03:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331427#M30632</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2017-01-27T18:03:02Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331428#M30633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for the confirmation that there is no event that is fired when the view is finished drawing.&amp;nbsp; I thought that I was missing something when going through the api reference guide.&amp;nbsp; Seems like an odd and&amp;nbsp;incredibly useful&amp;nbsp;event to leave out.&amp;nbsp; I will probably just&amp;nbsp;wait for the "Coming Soon" busyIndicator then. &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 18:38:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331428#M30633</guid>
      <dc:creator>BobNichols</dc:creator>
      <dc:date>2017-01-27T18:38:39Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331429#M30634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;The busyIndicator is a simple helper class to do the DOM&amp;nbsp;work for you and show a indicator based on the show and hide methods. It would still have to be triggerd by an event or function. So what we are really waiting for is a updating-end event or the likes that the 3.x api has.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jan 2017 18:49:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331429#M30634</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2017-01-27T18:49:51Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331430#M30635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The LayerList widget actually has a little animated horizontal bar for each layer while it's loading and stops when is complete. See&amp;nbsp;&lt;A class="link-titled" href="https://developers.arcgis.com/javascript/latest/sample-code/widgets-layerlist/index.html" title="https://developers.arcgis.com/javascript/latest/sample-code/widgets-layerlist/index.html"&gt;LayerList widget | ArcGIS API for JavaScript 4.2&lt;/A&gt;&amp;nbsp;.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jan 2017 13:10:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331430#M30635</guid>
      <dc:creator>DavidChrest</dc:creator>
      <dc:date>2017-01-30T13:10:24Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331431#M30636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Waiting for the BusyIndicator, this can be easily achieved watching the property "updating" of your view and dojo Toggler&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loading = new Toggler({&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;node: "loadingImg"&lt;BR /&gt; });&lt;/P&gt;&lt;P&gt;&lt;BR /&gt; app.mapView.watch("updating", function (updating) {&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;updatingViewChange(updating);&lt;BR /&gt; });&lt;/P&gt;&lt;P&gt;function updatingViewChange(updating)&lt;BR /&gt; { &lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;if (updating) {&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;loading.show();&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;else {&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;loading.hide();&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR /&gt; }&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Apr 2017 09:05:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331431#M30636</guid>
      <dc:creator>DavideLimosani</dc:creator>
      <dc:date>2017-04-11T09:05:33Z</dc:date>
    </item>
    <item>
      <title>Re: Map Loading Progress Bar/Animation Javascript 4.x</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331432#M30637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In the current version (v4.10) it is possible to display a "loading" indicator by using &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-core-watchUtils.html" rel="nofollow noopener noreferrer" target="_blank"&gt;watchUtils&lt;/A&gt;&amp;nbsp;and looking at the view's &lt;A href="https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#updating" rel="nofollow noopener noreferrer" target="_blank"&gt;updating&lt;/A&gt; property:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;// Display the loading indicator when the view is updating
watchUtils.whenTrue(view, "updating", function(evt) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;$("#loading").show();
});

// Hide the loading indicator when the view stops updating
watchUtils.whenFalse(view, "updating", function(evt) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;$("#loading").hide();
});

&lt;/PRE&gt;&lt;P&gt;See a working demo at &lt;A class="link-titled" href="https://codepen.io/slead/pen/QYwNJo" title="https://codepen.io/slead/pen/QYwNJo" rel="nofollow noopener noreferrer" target="_blank"&gt;Show a loading indicator using ArcGIS JS API v4&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 16:21:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/map-loading-progress-bar-animation-javascript-4-x/m-p/331432#M30637</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2021-12-12T16:21:05Z</dc:date>
    </item>
  </channel>
</rss>

