<?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: Arcade expression based conditional formatting for labels? in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-based-conditional-formatting-for/m-p/1506747#M85715</link>
    <description>&lt;P&gt;Check out &lt;A href="https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm" target="_blank"&gt;https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;For your expression, you'll want the &amp;lt;CLR&amp;gt; tags.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;if ($feature.TYPE == 'A'){
     `&amp;lt;CLR red='255'&amp;gt;${$feature.NAME}&amp;lt;/CLR&amp;gt;`
} else {
     `&amp;lt;CLR blue='255'&amp;gt;${$feature.NAME}&amp;lt;/CLR&amp;gt;`
}&lt;/LI-CODE&gt;</description>
    <pubDate>Thu, 18 Jul 2024 17:11:28 GMT</pubDate>
    <dc:creator>jcarlson</dc:creator>
    <dc:date>2024-07-18T17:11:28Z</dc:date>
    <item>
      <title>Arcade expression based conditional formatting for labels?</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-based-conditional-formatting-for/m-p/1506745#M85713</link>
      <description>&lt;P&gt;Is there any way for me to use arcade to make conditional formatting of the text in labels in ArcPRO?&lt;BR /&gt;&lt;BR /&gt;Something along the lines of:&lt;BR /&gt;&lt;BR /&gt;if ($feature.TYPE == 'A'){&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;text color = "Red"&amp;gt;$feature.NAME&amp;lt;/text&amp;gt;}&lt;BR /&gt;else{&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;text color = "Blue"&amp;gt;$feature.NAME&amp;lt;/text&amp;gt;};&lt;BR /&gt;&lt;BR /&gt;I suppose I could copy the layer, and definition query out the features I want, and then label them in separate layers, but I'm wondering if there is a way to conditionally format text in arcade.&lt;/P&gt;</description>
      <pubDate>Thu, 18 Jul 2024 17:06:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-based-conditional-formatting-for/m-p/1506745#M85713</guid>
      <dc:creator>DavidCantor</dc:creator>
      <dc:date>2024-07-18T17:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade expression based conditional formatting for labels?</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-based-conditional-formatting-for/m-p/1506747#M85715</link>
      <description>&lt;P&gt;Check out &lt;A href="https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm" target="_blank"&gt;https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;For your expression, you'll want the &amp;lt;CLR&amp;gt; tags.&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;if ($feature.TYPE == 'A'){
     `&amp;lt;CLR red='255'&amp;gt;${$feature.NAME}&amp;lt;/CLR&amp;gt;`
} else {
     `&amp;lt;CLR blue='255'&amp;gt;${$feature.NAME}&amp;lt;/CLR&amp;gt;`
}&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 18 Jul 2024 17:11:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-based-conditional-formatting-for/m-p/1506747#M85715</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2024-07-18T17:11:28Z</dc:date>
    </item>
  </channel>
</rss>

