<?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 Error in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555909#M89852</link>
    <description>&lt;P&gt;The second DomainName appears to be incorrect. You have double quote before L but no closing double quote, no value, an extra 'n/a', and an extra parenthesis. Should that be like this?&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;if (DomainName($feature, "systemBasisOfClassification1", "A) Records Review", "n/a") == "A) Records Review" &amp;amp;&amp;amp;
    DomainName($feature, "systeminstallationDateRange", "L) 1991-2000", "n/a") == "L) 1991-2000") {
  return DomainName($feature, "serviceLineClassification", "Non-Lead", "n/a");
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 06 Nov 2024 17:34:44 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2024-11-06T17:34:44Z</dc:date>
    <item>
      <title>Arcade Expression Error</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555902#M89849</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to figure out how to write an arcade expression that will populate 1 field based off of the values in 4 other fields. I am using attribute rules and still very green to arcade expression. I would also like the attribute rules to work in field maps. When our field crews go out they will be filling in the 4 fields mentioned above and I am having trouble piecing this expression together.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Field Name to Auto Populate:&lt;/STRONG&gt; serviceLineClassification&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;Field Names to Trigger Auto Populate&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;systemBasisOfClassification1&lt;/P&gt;&lt;P&gt;systemInstallationDateRange&lt;/P&gt;&lt;P&gt;customerBasisOfClassification1&lt;/P&gt;&lt;P&gt;customerInstallationDateRange&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt; All of the fields have domains connected to them. The expression I put together below is just the first of many as I need to cover all of the variables. However, I am having trouble getting the first expression together.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Expression I Tried:&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;if (DomainName($feature, 'systemBasisOfClassification1', 'A) Records Review', "n/a") == 'A) Records Review' &amp;amp;&amp;amp; DomainName($feature, 'systeminstallationDateRange', 'n/a') == "L) 1991-2000', 'n/a')) {return DomainName($feature, 'serviceLineClassification', 'Non-Lead', 'n/a')}&lt;/P&gt;&lt;P&gt;Hope all of this makes sense and in advanced thanks to anyone who can help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2024 17:13:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555902#M89849</guid>
      <dc:creator>Austin_Shettler</dc:creator>
      <dc:date>2024-11-06T17:13:26Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade Expression Error</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555908#M89851</link>
      <description>&lt;P&gt;I dont have much experience with the DomainName function, but I often will run attribute rules on fields that have domains without using it and have no problems. One thing I see is that there might be some mismatched quotes (single vs double to encase a text string). I might be wrong but you could look at that.&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;var sysClass = $feature.systemBasisOfClassification1
var sysInst = $feature.systeminstallationDateRange

var c = WHEN(sysClass=='A) Records Review' &amp;amp;&amp;amp; sysInst == 'L) 1991-2000','Non-Lead','UNKNOWN')
return c&lt;/LI-CODE&gt;&lt;P&gt;You might be able to simplify a bit by using something like the above. You'd be able to add additional subsets of the WHEN function just by adjusting the values from your dataset.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2024 17:34:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555908#M89851</guid>
      <dc:creator>ZachBodenner</dc:creator>
      <dc:date>2024-11-06T17:34:42Z</dc:date>
    </item>
    <item>
      <title>Re: Arcade Expression Error</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555909#M89852</link>
      <description>&lt;P&gt;The second DomainName appears to be incorrect. You have double quote before L but no closing double quote, no value, an extra 'n/a', and an extra parenthesis. Should that be like this?&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;if (DomainName($feature, "systemBasisOfClassification1", "A) Records Review", "n/a") == "A) Records Review" &amp;amp;&amp;amp;
    DomainName($feature, "systeminstallationDateRange", "L) 1991-2000", "n/a") == "L) 1991-2000") {
  return DomainName($feature, "serviceLineClassification", "Non-Lead", "n/a");
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2024 17:34:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/arcade-expression-error/m-p/1555909#M89852</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2024-11-06T17:34:44Z</dc:date>
    </item>
  </channel>
</rss>

