<?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 Arcade in pop up in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109254#M42662</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Would anyone please be willing to share how to display quarterly inspection results in a pop up using Arcade? I’m at a loss. Below is an example of what I’ve tried so far:&lt;/P&gt;&lt;P&gt;var Q3E = Date(2021,09,01);&lt;/P&gt;&lt;P&gt;var Q3S = Date(2021,05,01);&lt;/P&gt;&lt;P&gt;var CD = FeatureSetByRelationshipName($feature,"InsTable",["InsDate"]);&lt;/P&gt;&lt;P&gt;var CR = IIF(CD &amp;lt; Q3E &amp;amp;&amp;amp; CD &amp;gt;= Q3S, "InsRead", "No Data");&lt;/P&gt;&lt;P&gt;return CR;&lt;/P&gt;</description>
    <pubDate>Wed, 20 Oct 2021 15:17:34 GMT</pubDate>
    <dc:creator>DEI</dc:creator>
    <dc:date>2021-10-20T15:17:34Z</dc:date>
    <item>
      <title>Arcade in pop up</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109254#M42662</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Would anyone please be willing to share how to display quarterly inspection results in a pop up using Arcade? I’m at a loss. Below is an example of what I’ve tried so far:&lt;/P&gt;&lt;P&gt;var Q3E = Date(2021,09,01);&lt;/P&gt;&lt;P&gt;var Q3S = Date(2021,05,01);&lt;/P&gt;&lt;P&gt;var CD = FeatureSetByRelationshipName($feature,"InsTable",["InsDate"]);&lt;/P&gt;&lt;P&gt;var CR = IIF(CD &amp;lt; Q3E &amp;amp;&amp;amp; CD &amp;gt;= Q3S, "InsRead", "No Data");&lt;/P&gt;&lt;P&gt;return CR;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 15:17:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109254#M42662</guid>
      <dc:creator>DEI</dc:creator>
      <dc:date>2021-10-20T15:17:34Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade in pop up</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109275#M42663</link>
      <description>&lt;P&gt;In your expression, you're trying to filter the &lt;STRONG&gt;FeatureSet&lt;/STRONG&gt; CD by dates. In order to do this, you need to actually use&lt;A href="https://developers.arcgis.com/arcade/function-reference/data_functions/#filter" target="_blank"&gt; the &lt;STRONG&gt;Filter&lt;/STRONG&gt; function&lt;/A&gt;.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var CR = Filter(CD, "InsDate &amp;lt; @Q3E AND InsDate &amp;gt;= @Q3S")&lt;/LI-CODE&gt;&lt;P&gt;Note that this will still only return a &lt;STRONG&gt;FeatureSet&lt;/STRONG&gt;. In order to access the attributes of individual features, you will need to use a &lt;A href="https://developers.arcgis.com/arcade/guide/logic/#for-loops" target="_blank"&gt;for loop&lt;/A&gt; or some other function.&lt;/P&gt;&lt;P&gt;Can you give more details on what the popup ought to look like? Do you want summary statistics of the inspection results, a single attribute, a row per inspection? Other inspection fields? Right now, your inspections FeatureSet only includes the "InsDate" field, nothing else.&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 15:38:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109275#M42663</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2021-10-20T15:38:12Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade in pop up</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109318#M42665</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/363906"&gt;@jcarlson&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;I would like to display a single attribute for each quarter in the pop up. Something like this:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="DEI_0-1634745104486.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/25647i6EDCC0073CEE7C25/image-size/medium?v=v2&amp;amp;px=400" role="button" title="DEI_0-1634745104486.png" alt="DEI_0-1634745104486.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Where each expression returns the inspection result. My thought was if I could evaluate each point's inspection dates to see if any fall within a range (or quarter), I could then return the result that was recorded from that particular date. I hope that answers your questions. I appreciate your help!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 16:08:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109318#M42665</guid>
      <dc:creator>DEI</dc:creator>
      <dc:date>2021-10-20T16:08:29Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade in pop up</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109333#M42666</link>
      <description>&lt;P&gt;Got it. So, assuming that you've only got one inspection per quarter, you could use the &lt;STRONG&gt;First&lt;/STRONG&gt; function. Also, since you're wanting the inspection results in your output, we need to include that in the FeatureSet.&lt;/P&gt;&lt;P&gt;Thinking about it more, too, we can include some SQL in the &lt;STRONG&gt;Filter &lt;/STRONG&gt;function to get the appropriate quarter without&amp;nbsp; the need to create additional variables.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var CD = FeatureSetByRelationshipName($feature,"InsTable",["InsDate", "inspection-results-field"]);

// Filter for certain months of 2021
var CR = Filter(CD, "InsDate &amp;lt; '09/01/2021' AND InsDate &amp;gt;= '05/01/2021'")

if(Count(CR) &amp;gt; 0){
    return First(CR)["inspection-results-field"]
} else {
    return "No Data"
}&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 20 Oct 2021 16:32:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109333#M42666</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2021-10-20T16:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade in pop up</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109351#M42667</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/363906"&gt;@jcarlson&lt;/a&gt;&amp;nbsp;you are brilliant!!&lt;/P&gt;&lt;P&gt;That worked perfectly - thank you much!&lt;/P&gt;</description>
      <pubDate>Wed, 20 Oct 2021 17:35:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/arcade-in-pop-up/m-p/1109351#M42667</guid>
      <dc:creator>DEI</dc:creator>
      <dc:date>2021-10-20T17:35:06Z</dc:date>
    </item>
  </channel>
</rss>

