<?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: Replace values with text using Arcade in a list in ArcGIS Dashboards Questions</title>
    <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320265#M8331</link>
    <description>&lt;P&gt;You should use the &lt;A href="https://developers.arcgis.com/arcade/function-reference/logical_functions/#when" target="_self"&gt;When&lt;/A&gt; function. Is the field numeric or a string?&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;//if it's a number
var over = When($datapoint['IsOverriden'] == 0, 'No',
                $datapoint['IsOverriden'] == 1, 'Yes',
                '');
//if it's a string
var over = When($datapoint['IsOverriden'] == '0', 'No',
                $datapoint['IsOverriden'] == '1', 'Yes',
                '');&lt;/LI-CODE&gt;</description>
    <pubDate>Fri, 18 Aug 2023 18:47:15 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2023-08-18T18:47:15Z</dc:date>
    <item>
      <title>Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320262#M8330</link>
      <description>&lt;P&gt;How would I convert values (0,1) with yes/no in a list?&lt;/P&gt;&lt;P&gt;This is what I tried but not right&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_0-1692383872574.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78538i65B218D2950E5BAF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dwold_0-1692383872574.png" alt="dwold_0-1692383872574.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_2-1692383948626.png" style="width: 171px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78541i89CF22AE8C50ABA0/image-dimensions/171x158?v=v2" width="171" height="158" role="button" title="dwold_2-1692383948626.png" alt="dwold_2-1692383948626.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Data Table:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_1-1692383902087.png" style="width: 141px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78539i9358CC74DABC01D8/image-dimensions/141x186?v=v2" width="141" height="186" role="button" title="dwold_1-1692383902087.png" alt="dwold_1-1692383902087.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2023 18:40:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320262#M8330</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-18T18:40:51Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320265#M8331</link>
      <description>&lt;P&gt;You should use the &lt;A href="https://developers.arcgis.com/arcade/function-reference/logical_functions/#when" target="_self"&gt;When&lt;/A&gt; function. Is the field numeric or a string?&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;//if it's a number
var over = When($datapoint['IsOverriden'] == 0, 'No',
                $datapoint['IsOverriden'] == 1, 'Yes',
                '');
//if it's a string
var over = When($datapoint['IsOverriden'] == '0', 'No',
                $datapoint['IsOverriden'] == '1', 'Yes',
                '');&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 18 Aug 2023 18:47:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320265#M8331</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2023-08-18T18:47:15Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320272#M8332</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/2839"&gt;@KenBuja&lt;/a&gt;&amp;nbsp;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2023 18:53:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320272#M8332</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-18T18:53:31Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320325#M8334</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/2839"&gt;@KenBuja&lt;/a&gt;&amp;nbsp;If I wanted to hide the Override line if the value is 0 would that be done through an if statement? Or can that still be done using the when statement?&lt;/P&gt;&lt;P&gt;Showing only records that have 1/yes&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_0-1692388895593.png" style="width: 295px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78557i835B8274A7BF9F32/image-dimensions/295x118?v=v2" width="295" height="118" role="button" title="dwold_0-1692388895593.png" alt="dwold_0-1692388895593.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_1-1692388927825.png" style="width: 298px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78558i1E7FFB290C1C4FD8/image-dimensions/298x108?v=v2" width="298" height="108" role="button" title="dwold_1-1692388927825.png" alt="dwold_1-1692388927825.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Aug 2023 20:19:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320325#M8334</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-18T20:19:54Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320633#M8335</link>
      <description>&lt;P&gt;How are you constructing the text block?&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 12:47:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320633#M8335</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2023-08-21T12:47:07Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320710#M8336</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/2839"&gt;@KenBuja&lt;/a&gt;&amp;nbsp;I removed the == 0, 'No', line thinking the list would remove/hide the 0 values, but it still read Score override:&amp;nbsp; (because that is part of the text block)&lt;/P&gt;&lt;P&gt;(didn't think it would be that easy but gave it a shot)&lt;/P&gt;&lt;P&gt;Doing this:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_0-1692629954275.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78683i89031EEF72CE40CF/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dwold_0-1692629954275.png" alt="dwold_0-1692629954275.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;and then:&lt;/P&gt;&lt;P&gt;{expression/icon}&lt;/P&gt;&lt;P&gt;{AssesmentName}&lt;/P&gt;&lt;P&gt;Created on&amp;nbsp;{expression/create}&lt;/P&gt;&lt;P&gt;Created by&amp;nbsp;{Creator}&lt;/P&gt;&lt;P&gt;Score override:&amp;nbsp;{expression/over}&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 15:15:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320710#M8336</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-21T15:15:39Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320735#M8337</link>
      <description>&lt;P&gt;Instead of putting "Score override: " in the text block, add that in the expression only if the value is "Yes"&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;If ($datapoint['IsOverriden'] == 1) return 'Score override: Yes';&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 21 Aug 2023 15:28:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320735#M8337</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2023-08-21T15:28:32Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320864#M8341</link>
      <description>&lt;P&gt;Great, thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 19:07:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1320864#M8341</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-21T19:07:14Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321083#M8345</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/2839"&gt;@KenBuja&lt;/a&gt;&amp;nbsp;I'm new to arcade so I don't think I am doing something right. When I remove the text block that line is deleted (even values with 1/yes). Does the return call look in the right spot? See anything that I am doing wrong?&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_0-1692704093940.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78770i58B2F52C8D9D249C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dwold_0-1692704093940.png" alt="dwold_0-1692704093940.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_1-1692704115654.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78771iBA735351274327DB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dwold_1-1692704115654.png" alt="dwold_1-1692704115654.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="dwold_2-1692704150924.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/78772i2111692F361CA0B7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="dwold_2-1692704150924.png" alt="dwold_2-1692704150924.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Aug 2023 11:38:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321083#M8345</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-22T11:38:53Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321159#M8346</link>
      <description>&lt;P&gt;I'm sorry, I was incorrect. That should be&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;If ($datapoint['IsOverriden'] == 1) var over = 'Score override: Yes';&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Keep 'over' in the attributes and {expression/over} in the template&lt;/P&gt;</description>
      <pubDate>Tue, 22 Aug 2023 14:21:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321159#M8346</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2023-08-22T14:21:02Z</dc:date>
    </item>
    <item>
      <title>Re: Replace values with text using Arcade in a list</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321341#M8349</link>
      <description>&lt;P&gt;Great, worked perfectly! Thank you!&lt;/P&gt;</description>
      <pubDate>Tue, 22 Aug 2023 19:22:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/replace-values-with-text-using-arcade-in-a-list/m-p/1321341#M8349</guid>
      <dc:creator>dwold</dc:creator>
      <dc:date>2023-08-22T19:22:00Z</dc:date>
    </item>
  </channel>
</rss>

