<?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: Help needed: arcade expression for attribute rule in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514146#M86365</link>
    <description>&lt;P&gt;Could you please give a little more information about what you mean by "doesn't work"? Do you receive an error message? Are the returned values incorrect?&lt;/P&gt;</description>
    <pubDate>Fri, 02 Aug 2024 12:56:14 GMT</pubDate>
    <dc:creator>ZachBodenner</dc:creator>
    <dc:date>2024-08-02T12:56:14Z</dc:date>
    <item>
      <title>Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514144#M86364</link>
      <description>&lt;P&gt;Dear community,&lt;/P&gt;&lt;P&gt;I have two attributes:&lt;BR /&gt;1) gebnr (this is the number of the studied field, le.g. 1 or 135...)&lt;BR /&gt;2) ID (this is the number of the studied field filled up to four digits, e.g. 1 -&amp;gt; 0001 or 135 -&amp;gt; 0135...)&lt;/P&gt;&lt;P&gt;I'd like to automatize the filling of the ID-attribute. I've tried to code a attribute rule, that says if&lt;BR /&gt;- gebnr &amp;lt; 10 then ID=000gebnr&lt;BR /&gt;- gebnr &amp;gt;=10 and gebnr&amp;lt;100 then ID=00gebnr&lt;BR /&gt;- gebnr&amp;gt;=100 and gebnr&amp;lt;1000 then ID=0gebnr&lt;BR /&gt;- gebnr&amp;gt;=1000 then ID=gebnr&lt;/P&gt;&lt;P&gt;My coding for ID looks like this now but it doesn't work (I have no experience in arcade at all):&lt;BR /&gt;var gebnr = $feature.GEBNRA&lt;BR /&gt;var ranking = When(gebnr &amp;lt; 10, Concatenate(000,gebnr), gebnr &amp;gt;=10 &amp;amp;&amp;amp; gebnr &amp;lt; 100, Concatenate(00,gebnr), gebnr &amp;gt;= 100 &amp;amp;&amp;amp; gebnr &amp;lt; 1000, Concatenate(0,gebnr), gebnr &amp;gt;= 1000, gebnr,-1);&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;&lt;P&gt;(Please, don't ask why these redundant attributes are necessary, it's German bureaucracy &lt;span class="lia-unicode-emoji" title=":grinning_face_with_smiling_eyes:"&gt;😄&lt;/span&gt; )&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 12:48:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514144#M86364</guid>
      <dc:creator>christlmistl</dc:creator>
      <dc:date>2024-08-02T12:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514146#M86365</link>
      <description>&lt;P&gt;Could you please give a little more information about what you mean by "doesn't work"? Do you receive an error message? Are the returned values incorrect?&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 12:56:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514146#M86365</guid>
      <dc:creator>ZachBodenner</dc:creator>
      <dc:date>2024-08-02T12:56:14Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514159#M86366</link>
      <description>&lt;P&gt;doesn't work means, that if I create for instance a new polygon and enter the gebnr = 1, the ID attribute stays at &amp;lt;NULL&amp;gt;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 13:13:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514159#M86366</guid>
      <dc:creator>christlmistl</dc:creator>
      <dc:date>2024-08-02T13:13:27Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514162#M86367</link>
      <description>&lt;P&gt;You can use the Text function for this:&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;return Text($feature.GEBNRA, '0000');&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 02 Aug 2024 13:19:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514162#M86367</guid>
      <dc:creator>ChrisFox</dc:creator>
      <dc:date>2024-08-02T13:19:39Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514178#M86370</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/820128"&gt;@christlmistl&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/74321"&gt;@ChrisFox&lt;/a&gt;&amp;nbsp;answer is the simplest solution to your problem. I would suggest for you to also research the 'console' function which will enable you to see the result in the messages.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 13:49:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514178#M86370</guid>
      <dc:creator>RPGIS</dc:creator>
      <dc:date>2024-08-02T13:49:39Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514184#M86372</link>
      <description>&lt;P&gt;Can you show a screenshot of your attribute rule?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 14:15:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514184#M86372</guid>
      <dc:creator>ZachBodenner</dc:creator>
      <dc:date>2024-08-02T14:15:09Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514224#M86380</link>
      <description>&lt;P&gt;What is the datatype for the ID field?&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 15:51:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514224#M86380</guid>
      <dc:creator>Dan_DMR</dc:creator>
      <dc:date>2024-08-02T15:51:37Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed: arcade expression for attribute rule</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514272#M86383</link>
      <description>&lt;P&gt;Thank you all for your help!&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/74321"&gt;@ChrisFox&lt;/a&gt;&amp;nbsp;answer solved the problem &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 02 Aug 2024 16:58:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/help-needed-arcade-expression-for-attribute-rule/m-p/1514272#M86383</guid>
      <dc:creator>christlmistl</dc:creator>
      <dc:date>2024-08-02T16:58:44Z</dc:date>
    </item>
  </channel>
</rss>

