<?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: Attribute Expression for popup not working. in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366306#M56665</link>
    <description>&lt;P&gt;Hi...added the console function and it returns N/A? The values for CURR_PHASE are in a domain called CIP_CURRENT_PHASE&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sanderson_OC_0-1704383235407.png" style="width: 286px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90516i0A3BA488EC901550/image-dimensions/286x161?v=v2" width="286" height="161" role="button" title="sanderson_OC_0-1704383235407.png" alt="sanderson_OC_0-1704383235407.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 04 Jan 2024 15:48:55 GMT</pubDate>
    <dc:creator>sanderson_OC</dc:creator>
    <dc:date>2024-01-04T15:48:55Z</dc:date>
    <item>
      <title>Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366063#M56639</link>
      <description>&lt;P&gt;Hi, I am struggling with Arcade Expressions! I have a web map in agol that I am trying to customize the popup. I want to display different text based on the project status.&lt;/P&gt;&lt;P&gt;So if the Current Phase = Construction,&lt;/P&gt;&lt;P&gt;I want to display a sentence like "&lt;SPAN&gt;&lt;I&gt;Project started in the {PROJ_BEGIN} of {BEGIN_YEAR} and is expected to be completed in the {PROJ_END} of {END_YEAR} "&lt;/I&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;my attribute expression&lt;/U&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;var&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;=&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;$feature&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;CURR_PHASE&lt;/SPAN&gt;&lt;SPAN&gt;;&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;var&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;phrase&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;=&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;When&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;(&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;==&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;'Construction'&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;"construction sentence&amp;nbsp;here"&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;==&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;'Design'&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;"design sentence here"&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;==&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;'Completed'&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;"completed sentence here"&lt;/SPAN&gt;&lt;SPAN&gt;,&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;"N/A"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;return&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;phrase&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;My popup is only displays N/A, it's not reading the value, obviously I am missing something??&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sanderson_OC_0-1704322213278.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90447i90F81CA898E35A05/image-size/medium?v=v2&amp;amp;px=400" role="button" title="sanderson_OC_0-1704322213278.png" alt="sanderson_OC_0-1704322213278.png" /&gt;&lt;/span&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Any suggests would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 03 Jan 2024 22:52:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366063#M56639</guid>
      <dc:creator>sanderson_OC</dc:creator>
      <dc:date>2024-01-03T22:52:00Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366297#M56663</link>
      <description>&lt;P&gt;That expression should work. What are the values in the field "CURR_PHASE"? You can see what is getting returned by adding in the console function in line 2.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var status = $feature.CURR_PHASE;
console($feature.CURR_PHASE)
var phrase = When (status == 'Construction', "construction sentence here",
                   status == 'Design', "design sentence here", 
                   status == 'Completed', "completed sentence here", 
                   "N/A")
return phrase;&lt;/LI-CODE&gt;&lt;P&gt;In the popup expression window, click Run, then click the Console tab to see the results&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="console1.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90513iBF28C3EC4FEAF4D0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="console1.png" alt="console1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;</description>
      <pubDate>Thu, 04 Jan 2024 15:31:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366297#M56663</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2024-01-04T15:31:32Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366306#M56665</link>
      <description>&lt;P&gt;Hi...added the console function and it returns N/A? The values for CURR_PHASE are in a domain called CIP_CURRENT_PHASE&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sanderson_OC_0-1704383235407.png" style="width: 286px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90516i0A3BA488EC901550/image-dimensions/286x161?v=v2" width="286" height="161" role="button" title="sanderson_OC_0-1704383235407.png" alt="sanderson_OC_0-1704383235407.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jan 2024 15:48:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366306#M56665</guid>
      <dc:creator>sanderson_OC</dc:creator>
      <dc:date>2024-01-04T15:48:55Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366310#M56666</link>
      <description>&lt;P&gt;Here is the information on that field...doesn't seem to be any issues there? Thank you so much for the help I have been driving myself crazy trying to get something to work!&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="sanderson_OC_1-1704383462165.png" style="width: 256px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/90517i6729F40ED0E2549A/image-dimensions/256x235?v=v2" width="256" height="235" role="button" title="sanderson_OC_1-1704383462165.png" alt="sanderson_OC_1-1704383462165.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any ideas or maybe another work around? Because those values are in a domain do I need for reference them a different way?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jan 2024 15:53:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366310#M56666</guid>
      <dc:creator>sanderson_OC</dc:creator>
      <dc:date>2024-01-04T15:53:37Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366320#M56667</link>
      <description>&lt;P&gt;Oops sorry, I forgot to click on the console tab! It is showing Closeout. So I updated to add all the values. But still showing N/A in popup?&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;$feature&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;CURR_PHASE&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;console&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;$feature&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;CURR_PHASE&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;var&lt;/SPAN&gt; &lt;SPAN&gt;phrase&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;When&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; == &lt;/SPAN&gt;&lt;SPAN&gt;'Construction'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"construction sentence here"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; == &lt;/SPAN&gt;&lt;SPAN&gt;'Design'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"design sentence here"&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; == &lt;/SPAN&gt;&lt;SPAN&gt;'Completed'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"completed sentence here"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; == &lt;/SPAN&gt;&lt;SPAN&gt;'Closeout'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"completed project"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;status&lt;/SPAN&gt;&lt;SPAN&gt; == &lt;/SPAN&gt;&lt;SPAN&gt;'Study'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"only looking for now"&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;"N/A"&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;return&lt;/SPAN&gt; &lt;SPAN&gt;phrase&lt;/SPAN&gt;&lt;SPAN&gt;;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 04 Jan 2024 16:10:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366320#M56667</guid>
      <dc:creator>sanderson_OC</dc:creator>
      <dc:date>2024-01-04T16:10:36Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366331#M56669</link>
      <description>&lt;P&gt;Having them in a domain makes a difference. You just have to make one change&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;var status = DomainName($feature, 'CURR_PHASE')&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 04 Jan 2024 16:25:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366331#M56669</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2024-01-04T16:25:02Z</dc:date>
    </item>
    <item>
      <title>Re: Attribute Expression for popup not working.</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366337#M56670</link>
      <description>&lt;P&gt;Oh thank you so much! It worked when I added that line. I am eternally grateful &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jan 2024 17:07:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/attribute-expression-for-popup-not-working/m-p/1366337#M56670</guid>
      <dc:creator>sanderson_OC</dc:creator>
      <dc:date>2024-01-04T17:07:46Z</dc:date>
    </item>
  </channel>
</rss>

