<?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 Getting Symbol from GraphicElement? in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/getting-symbol-from-graphicelement/m-p/851259#M3835</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a Layout that contains various graphic elements. I want to get the symbol from a specific graphic element in order to apply it to the renderer of a layer within a map in a mapFrame in the Layout.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the .NET SDK, this is fairly simple - you can reference graphicElement.Graphic.Symbol (which is a CIMSymbolReference), and then assign that Symbol to the Symbol property of a CIMUniqueValueClass.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The corresponding logic in ArcPy would be to assign something to the symbol property of an Item, which is part of an ItemGroup, which exists within the groups property of your UniqueValueRenderer. However, I'm not seeing any way to get the specific symbol that a specific graphic element is using.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The documentation for symbol says, "&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;The easiest way to update a symbol is to use the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="background-color: #ffffff; font-size: 17px;"&gt;applySymbolFromGallery&lt;/SPAN&gt;&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;method." But what if we can't do that? The symbol I'm interested in isn't necessarily a stock, named symbol, but a symbol the user may have customized on their layout before this whole rendering process takes place.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;Is there some way to access what I need through the CIM (within Python)? If so, how would I take that CIM object and convert it into a Symbol object that can be assigned to an Item?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 31 Mar 2020 19:55:47 GMT</pubDate>
    <dc:creator>DavidLaMartina</dc:creator>
    <dc:date>2020-03-31T19:55:47Z</dc:date>
    <item>
      <title>Getting Symbol from GraphicElement?</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/getting-symbol-from-graphicelement/m-p/851259#M3835</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a Layout that contains various graphic elements. I want to get the symbol from a specific graphic element in order to apply it to the renderer of a layer within a map in a mapFrame in the Layout.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the .NET SDK, this is fairly simple - you can reference graphicElement.Graphic.Symbol (which is a CIMSymbolReference), and then assign that Symbol to the Symbol property of a CIMUniqueValueClass.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The corresponding logic in ArcPy would be to assign something to the symbol property of an Item, which is part of an ItemGroup, which exists within the groups property of your UniqueValueRenderer. However, I'm not seeing any way to get the specific symbol that a specific graphic element is using.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The documentation for symbol says, "&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;The easiest way to update a symbol is to use the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="" style="background-color: #ffffff; font-size: 17px;"&gt;applySymbolFromGallery&lt;/SPAN&gt;&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;method." But what if we can't do that? The symbol I'm interested in isn't necessarily a stock, named symbol, but a symbol the user may have customized on their layout before this whole rendering process takes place.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #4c4c4c; background-color: #ffffff;"&gt;Is there some way to access what I need through the CIM (within Python)? If so, how would I take that CIM object and convert it into a Symbol object that can be assigned to an Item?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 31 Mar 2020 19:55:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/getting-symbol-from-graphicelement/m-p/851259#M3835</guid>
      <dc:creator>DavidLaMartina</dc:creator>
      <dc:date>2020-03-31T19:55:47Z</dc:date>
    </item>
  </channel>
</rss>

