<?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: Auto-refresh attribute tables when the associated layer is set to a refresh interval in ArcGIS Web AppBuilder Questions</title>
    <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276224#M7335</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/98734" target="_blank"&gt;Jason Klrkland&lt;/A&gt;​,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you go into the \widgets\AttributeTable\Widget.js file and add&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;setInterval(lang.hitch(this, this.onRefreshButton),3000); // setInterval(expression,milliseconds);&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I added it right after the refresh button is called around line 1492, but I am sure it could be called other places as well. It would look something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.refreshButton = new Button({
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; label: this.nls.refresh,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; showLabel: true,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; iconClass: "esriAttributeTableRefreshImage",
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; onClick: lang.hitch(this, this.onRefreshButton)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; });
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setInterval(lang.hitch(this, this.onRefreshButton),3000); // setInterval(expression,milliseconds);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; toolbar.addChild(this.refreshButton);&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This calls the refresh of the attribute table every 3 seconds. I did notice that if the attribute table has lots of features or tables to load it takes a little longer. Also this will continue to refresh the attribute table even when it is closed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This would be great to have in the AGOL version too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With a little more work I am sure you could add it as a button to toggle the refresh option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Stan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 11 Dec 2021 13:27:30 GMT</pubDate>
    <dc:creator>StanMcShinsky</dc:creator>
    <dc:date>2021-12-11T13:27:30Z</dc:date>
    <item>
      <title>Auto-refresh attribute tables when the associated layer is set to a refresh interval</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276223#M7334</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just a feature request to have the attribute tables auto-refresh when their associated tables are set to a refresh interval.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A specific use case is a police/fire vehicle and call tracker where new calls and vehicles are updated on the map via a refresh interval on their layer.&amp;nbsp; Currently, only the map updates, not the associated attribute table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Mar 2015 16:31:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276223#M7334</guid>
      <dc:creator>JasonKlrkland</dc:creator>
      <dc:date>2015-03-23T16:31:43Z</dc:date>
    </item>
    <item>
      <title>Re: Auto-refresh attribute tables when the associated layer is set to a refresh interval</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276224#M7335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/98734" target="_blank"&gt;Jason Klrkland&lt;/A&gt;​,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you go into the \widgets\AttributeTable\Widget.js file and add&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;setInterval(lang.hitch(this, this.onRefreshButton),3000); // setInterval(expression,milliseconds);&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I added it right after the refresh button is called around line 1492, but I am sure it could be called other places as well. It would look something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.refreshButton = new Button({
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; label: this.nls.refresh,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; showLabel: true,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; iconClass: "esriAttributeTableRefreshImage",
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; onClick: lang.hitch(this, this.onRefreshButton)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; });
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setInterval(lang.hitch(this, this.onRefreshButton),3000); // setInterval(expression,milliseconds);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; toolbar.addChild(this.refreshButton);&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This calls the refresh of the attribute table every 3 seconds. I did notice that if the attribute table has lots of features or tables to load it takes a little longer. Also this will continue to refresh the attribute table even when it is closed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This would be great to have in the AGOL version too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With a little more work I am sure you could add it as a button to toggle the refresh option.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Stan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 13:27:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276224#M7335</guid>
      <dc:creator>StanMcShinsky</dc:creator>
      <dc:date>2021-12-11T13:27:30Z</dc:date>
    </item>
    <item>
      <title>Re: Auto-refresh attribute tables when the associated layer is set to a refresh interval</title>
      <link>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276225#M7336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Also if you did not want to see the little image flashing every time it reloads the just add this in the onRefreshButton function&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this.showRefreshing(false);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;like this around line 1555&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; onRefreshButton: function() {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (this.layersIndex &amp;gt; -1) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (this.grids[this.layersIndex]) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.grids[this.layersIndex].clearSelection();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (this.graphicsLayers[this.layersIndex]) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.graphicsLayers[this.layersIndex].clear();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }


&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.setSelectedNumber();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (this.config.layerInfos[this.layersIndex]) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.config.layerInfos[this.layersIndex].loaded = false;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.startQuery(this.layersIndex, this.config.layerInfos[this.layersIndex].extent);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.showRefreshing(false); //added this
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; },&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Stan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 13:27:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-web-appbuilder-questions/auto-refresh-attribute-tables-when-the-associated/m-p/276225#M7336</guid>
      <dc:creator>StanMcShinsky</dc:creator>
      <dc:date>2021-12-11T13:27:33Z</dc:date>
    </item>
  </channel>
</rss>

