<?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: Referencing a python variable in an arcade expression in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598516#M94282</link>
    <description>&lt;P&gt;Try using an F string&lt;/P&gt;&lt;LI-CODE lang="python"&gt;fieldVar = [f.name for f in arcpy.ListFields(fc)][0] # or whatever

arcEx = f"Text($feature.{fieldVar}) + "\n" + $feature.OBJECTID)&lt;/LI-CODE&gt;</description>
    <pubDate>Mon, 24 Mar 2025 14:22:32 GMT</pubDate>
    <dc:creator>AlfredBaldenweck</dc:creator>
    <dc:date>2025-03-24T14:22:32Z</dc:date>
    <item>
      <title>Referencing a python variable in an arcade expression</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598159#M94258</link>
      <description>&lt;P&gt;I have a python script which I am using to automate an otherwise tedious serious of intersects, joins and calculate fields. As part of this, I am calculating a field, DF_Sev, which is reliant upon a field which will be from one of the intersect functions (call it Field B). Field B is not guaranteed to have the same name each time this script is run, and is therefore stored as a variable. However, within the calculate field function for DF_Sev, the variable for Field B is not recognized within the arcade expression i am using. Is there a way for this field to be passed to the arcade expression, or do i need to find another workaround?&lt;/P&gt;</description>
      <pubDate>Fri, 21 Mar 2025 18:55:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598159#M94258</guid>
      <dc:creator>BSkaflen</dc:creator>
      <dc:date>2025-03-21T18:55:14Z</dc:date>
    </item>
    <item>
      <title>Re: Referencing a python variable in an arcade expression</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598516#M94282</link>
      <description>&lt;P&gt;Try using an F string&lt;/P&gt;&lt;LI-CODE lang="python"&gt;fieldVar = [f.name for f in arcpy.ListFields(fc)][0] # or whatever

arcEx = f"Text($feature.{fieldVar}) + "\n" + $feature.OBJECTID)&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 24 Mar 2025 14:22:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598516#M94282</guid>
      <dc:creator>AlfredBaldenweck</dc:creator>
      <dc:date>2025-03-24T14:22:32Z</dc:date>
    </item>
    <item>
      <title>Re: Referencing a python variable in an arcade expression</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598698#M94307</link>
      <description>&lt;P&gt;I was able to get around it by switching to a python expression, but I'll give this a shot as well!&lt;/P&gt;</description>
      <pubDate>Mon, 24 Mar 2025 19:06:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/referencing-a-python-variable-in-an-arcade/m-p/1598698#M94307</guid>
      <dc:creator>BSkaflen</dc:creator>
      <dc:date>2025-03-24T19:06:38Z</dc:date>
    </item>
  </channel>
</rss>

