<?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: Adding a feature class to a 3D Layer in Map_3D in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506722#M39849</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, they are defined as:&lt;/P&gt;&lt;P&gt;pPath&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;= project Path on disk (e.g. 'D:/..')&lt;/P&gt;&lt;P&gt;pName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;= project file name ('.aprx')&lt;/P&gt;&lt;P&gt;gdbName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;= path to GDB (usually sitting in the project path)&lt;/P&gt;&lt;P&gt;gdbName&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; = GDB name&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It indeed may be more a question, sorry about that..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;matt&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 23 Sep 2016 11:37:32 GMT</pubDate>
    <dc:creator>MatthiasBuehler</dc:creator>
    <dc:date>2016-09-23T11:37:32Z</dc:date>
    <item>
      <title>Adding a feature class to a 3D Layer in Map_3D</title>
      <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506720#M39847</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[ ArcGIS PRO 1.3.1 ]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm a bit stuck with arcpy when adding a feature class in the Map_3D viewer as a layer. Basically I'm trying to emulate the same thing that happens when drag-n-dropping a FC into the Contents pane, resp. the Map_3D viewer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code so far ..&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;import arcpy&lt;BR /&gt; aprx = arcpy.mp.ArcGISProject(pPath + pName)&lt;BR /&gt;&lt;BR /&gt; fc = gdbPath + gdbName + '/myFeatureClass'&lt;BR /&gt; lyr = arcpy.MakeFeatureLayer_management(fc, 'myLayer')&lt;BR /&gt;&lt;BR /&gt; for map in aprx.listMaps():&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;if map.mapType == 'SCENE':&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;map.addLayer(lyr, add_position = 'AUTO_ARRANGE')&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But this produces an error .. What am I missing?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for any input!&lt;/P&gt;&lt;P&gt;Matt&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Sep 2016 10:16:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506720#M39847</guid>
      <dc:creator>MatthiasBuehler</dc:creator>
      <dc:date>2016-09-23T10:16:28Z</dc:date>
    </item>
    <item>
      <title>Re: Adding a feature class to a 3D Layer in Map_3D</title>
      <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506721#M39848</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;are your variables defined somewhere else? ppath, pname, gdbpath, gdbname etc&lt;/P&gt;&lt;P&gt;this seems like a question rather than a discussion&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Sep 2016 10:41:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506721#M39848</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2016-09-23T10:41:59Z</dc:date>
    </item>
    <item>
      <title>Re: Adding a feature class to a 3D Layer in Map_3D</title>
      <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506722#M39849</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, they are defined as:&lt;/P&gt;&lt;P&gt;pPath&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;= project Path on disk (e.g. 'D:/..')&lt;/P&gt;&lt;P&gt;pName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;= project file name ('.aprx')&lt;/P&gt;&lt;P&gt;gdbName&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;= path to GDB (usually sitting in the project path)&lt;/P&gt;&lt;P&gt;gdbName&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp; = GDB name&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It indeed may be more a question, sorry about that..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;matt&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Sep 2016 11:37:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506722#M39849</guid>
      <dc:creator>MatthiasBuehler</dc:creator>
      <dc:date>2016-09-23T11:37:32Z</dc:date>
    </item>
    <item>
      <title>Re: Adding a feature class to a 3D Layer in Map_3D</title>
      <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506723#M39850</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well the reason I asked is because the error isn't specified and there is no way to check what it might be since the error may be due to the values of the parameters.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Sep 2016 13:14:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506723#M39850</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2016-09-23T13:14:00Z</dc:date>
    </item>
    <item>
      <title>Re: Adding a feature class to a 3D Layer in Map_3D</title>
      <link>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506724#M39851</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok, true. This is the error:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;Traceback (most recent call last):&lt;BR /&gt; File "Y:\..\pyScripts\createCables.py", line 25, in &amp;lt;module&amp;gt;&lt;BR /&gt; cc.createCables(pPath, pName, gdbPath, gdbName, pfc, mfc, rpk, lfc, a)&lt;BR /&gt; File "Y:\..\cableCode.py", line 456, in createCables&lt;BR /&gt; map.addLayer(lyr, add_position = 'AUTO_ARRANGE')&lt;BR /&gt; File "c:\program files\arcgis\pro\Resources\arcpy\arcpy\utils.py", line 191, in fn_&lt;BR /&gt; return fn(*args, **kw)&lt;BR /&gt; File "c:\program files\arcgis\pro\Resources\arcpy\arcpy\_mp.py", line 1041, in addLayer&lt;BR /&gt; return convertArcObjectToPythonObject(self._arc_object.addLayer(*gp_fixargs((add_layer_or_layerfile, add_position), True)))&lt;BR /&gt;ValueError: myLayer&lt;BR /&gt;Failed to execute (createCables).&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Sep 2016 13:38:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/adding-a-feature-class-to-a-3d-layer-in-map-3d/m-p/506724#M39851</guid>
      <dc:creator>MatthiasBuehler</dc:creator>
      <dc:date>2016-09-23T13:38:52Z</dc:date>
    </item>
  </channel>
</rss>

