<?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: Use hex codes in if/else statement using Arcade in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1330803#M54690</link>
    <description>&lt;P&gt;Can this be achieved in ArcPro?&lt;/P&gt;</description>
    <pubDate>Wed, 20 Sep 2023 19:39:57 GMT</pubDate>
    <dc:creator>SarahRijneke</dc:creator>
    <dc:date>2023-09-20T19:39:57Z</dc:date>
    <item>
      <title>Use hex codes in if/else statement using Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1067021#M40549</link>
      <description>&lt;P&gt;I have a custom pop-up where I'm using HTML and Arcade expressions to communicate whether or not a Library was included in an event. I have a large table built in the pop-up using HTML (see "HTML.txt") and inside that table, I have Arcade expressions using if/else statements to return an "X" if the result is true (or the Library was involved). I'm using a "1" in the attribute table indicating that a Library was involved and a "0" if they were not involved.&lt;/P&gt;&lt;P&gt;Here is an example of one arcade expression (titled: {expression/expr0}) which I then bring into the table HTML code (I have one arcade expression for each Library - probably not efficient, but I'm new to arcade!):&lt;/P&gt;&lt;P&gt;var X = $feature["Augsburg_Park"];&lt;BR /&gt;IIf (X == 1, 'X', '');&lt;/P&gt;&lt;P&gt;This results in a pop-up that looks like this:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Hannah_Hutchins_0-1623348488521.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/15660i78A61FF8DD9CF56A/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Hannah_Hutchins_0-1623348488521.png" alt="Hannah_Hutchins_0-1623348488521.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;Here is where I need help!&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;If a Library has an "X" in the table next to it (meaning it was included in an event), I would like to have the text (Library name and the "X") bolded and change colors (#00AEEF).&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;How do I integrate hex codes and font changes into an arcade expression?&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Jun 2021 18:13:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1067021#M40549</guid>
      <dc:creator>Hannah_Hutchins</dc:creator>
      <dc:date>2021-06-10T18:13:11Z</dc:date>
    </item>
    <item>
      <title>Re: Use hex codes in if/else statement using Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1067060#M40551</link>
      <description>&lt;P&gt;This blog article shows an approach for doing it.&amp;nbsp;&amp;nbsp;&lt;A href="https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/bring-colors-from-your-map-into-your-pop-up-using-arcade/" target="_blank"&gt;https://www.esri.com/arcgis-blog/products/arcgis-online/mapping/bring-colors-from-your-map-into-your-pop-up-using-arcade/&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Jun 2021 19:18:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1067060#M40551</guid>
      <dc:creator>MarkBockenhauer</dc:creator>
      <dc:date>2021-06-10T19:18:40Z</dc:date>
    </item>
    <item>
      <title>Re: Use hex codes in if/else statement using Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1330803#M54690</link>
      <description>&lt;P&gt;Can this be achieved in ArcPro?&lt;/P&gt;</description>
      <pubDate>Wed, 20 Sep 2023 19:39:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1330803#M54690</guid>
      <dc:creator>SarahRijneke</dc:creator>
      <dc:date>2023-09-20T19:39:57Z</dc:date>
    </item>
    <item>
      <title>Re: Use hex codes in if/else statement using Arcade</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1396680#M58139</link>
      <description>&lt;P&gt;This way listed above will not work. If you wish to do it in ArcPro follow this:&lt;/P&gt;&lt;P&gt;For hex values:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;FONT face="courier new,courier"&gt;#eb4034&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;For rgb values:&amp;nbsp;&lt;FONT face="courier new,courier"&gt;rgb(123,45,67)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;Example expression using hex with when statements and Arcade:&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="arcade_hexcodes.PNG" style="width: 323px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/98194i93287AACC295E5D0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="arcade_hexcodes.PNG" alt="arcade_hexcodes.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Mar 2024 17:18:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/use-hex-codes-in-if-else-statement-using-arcade/m-p/1396680#M58139</guid>
      <dc:creator>edward33</dc:creator>
      <dc:date>2024-03-15T17:18:35Z</dc:date>
    </item>
  </channel>
</rss>

