<?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 FeatureClassDefinitions from a Feature Service failed in ArcGIS Pro SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/getting-featureclassdefinitions-from-a-feature/m-p/837012#M3610</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have a Geodatabase that is connected to a SDE as well as a Geodatabase that is derived from a feature service. Both, SDE and Feature Server point to a database that maintains an Utility Network. In both cases we're not able to iterate through the feature definitions using the Pro SDK:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; sdeGeodatabase = &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Geodatabase(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; DatabaseConnectionFile(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Uri(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: maroon;"&gt;@"D:\Dokumente\ArcGIS\Packages\ElectricDistributionUtilityNetwork_9C8DDAA7-E710-43A4-9CF4-D136FEBD0B6D\utroot@vhm-sqlserv2016-UTProESRISampleData.sde"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;)));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; serviceGeodatabase = &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Geodatabase(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; ServiceConnectionProperties(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Uri(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: maroon;"&gt;@"&lt;A href="https://vhm-ut-portal.nbb.intern.aed-sicad.de/server/rest/services/Electric_Distribution_Utility_Network/FeatureServer"&gt;https://vhm-ut-portal.nbb.intern.aed-sicad.de/server/rest/services/Electric_Distribution_Utility_Network/FeatureServer&lt;/A&gt;"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;)));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;&lt;EM&gt;// Those calls working properly, retrieving the Standalone Tables...&lt;/EM&gt; &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; tableDefinitions1 = sdeGeodatabase.GetDefinitions&amp;lt;TableDefinition&amp;gt;().ToList();&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// works&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; tableDefinitions2 = serviceGeodatabase.GetDefinitions&amp;lt;TableDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// works&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;EM&gt;// Those calls fail, bringing up a COM Error-Message&lt;/EM&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; featureClassDefinition1 = sdeGeodatabase.GetDefinitions&amp;lt;FeatureClassDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// Error&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; featureClassDefinition2 = serviceGeodatabase.GetDefinitions&amp;lt;FeatureClassDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// Error&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In both cases the call to Geodatabase.GetDefinitions&amp;lt;FeatureClassDefinitions&amp;gt;() results in the following error message:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier\ new, courier, monospace;"&gt;System.Runtime.InteropServices.COMException: 'Ungültige Klassenzeichenfolge (Ausnahme von HRESULT: 0x800401F3 (CO_E_CLASSSTRING))'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry for the german here, translation is 'Invalid Class String' - HRESULT: 0x800401F3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We assume that it might have something to do with the Utility Network (especially the internal UN Business Tables) which might cause this issue. Retrieving a FeatureDatasetDefinition first is not an option, since a Feature Server does not support that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your suggestions. Would be great if we can resolve that somehow...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Karl&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 Feb 2018 16:17:47 GMT</pubDate>
    <dc:creator>KarlHuber</dc:creator>
    <dc:date>2018-02-19T16:17:47Z</dc:date>
    <item>
      <title>Getting FeatureClassDefinitions from a Feature Service failed</title>
      <link>https://community.esri.com/t5/arcgis-pro-sdk-questions/getting-featureclassdefinitions-from-a-feature/m-p/837012#M3610</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have a Geodatabase that is connected to a SDE as well as a Geodatabase that is derived from a feature service. Both, SDE and Feature Server point to a database that maintains an Utility Network. In both cases we're not able to iterate through the feature definitions using the Pro SDK:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; sdeGeodatabase = &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Geodatabase(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; DatabaseConnectionFile(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Uri(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: maroon;"&gt;@"D:\Dokumente\ArcGIS\Packages\ElectricDistributionUtilityNetwork_9C8DDAA7-E710-43A4-9CF4-D136FEBD0B6D\utroot@vhm-sqlserv2016-UTProESRISampleData.sde"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;)));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; serviceGeodatabase = &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Geodatabase(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; ServiceConnectionProperties(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;new&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; Uri(&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: maroon;"&gt;@"&lt;A href="https://vhm-ut-portal.nbb.intern.aed-sicad.de/server/rest/services/Electric_Distribution_Utility_Network/FeatureServer"&gt;https://vhm-ut-portal.nbb.intern.aed-sicad.de/server/rest/services/Electric_Distribution_Utility_Network/FeatureServer&lt;/A&gt;"&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;)));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt;&lt;EM&gt;// Those calls working properly, retrieving the Standalone Tables...&lt;/EM&gt; &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; tableDefinitions1 = sdeGeodatabase.GetDefinitions&amp;lt;TableDefinition&amp;gt;().ToList();&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// works&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; tableDefinitions2 = serviceGeodatabase.GetDefinitions&amp;lt;TableDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// works&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black; font-size: 9.5pt;"&gt;&lt;EM&gt;// Those calls fail, bringing up a COM Error-Message&lt;/EM&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; featureClassDefinition1 = sdeGeodatabase.GetDefinitions&amp;lt;FeatureClassDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// Error&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 9.5pt; color: blue;"&gt;var&lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: black;"&gt; featureClassDefinition2 = serviceGeodatabase.GetDefinitions&amp;lt;FeatureClassDefinition&amp;gt;().ToList(); &lt;/SPAN&gt;&lt;SPAN style="font-size: 9.5pt; color: green;"&gt;// Error&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In both cases the call to Geodatabase.GetDefinitions&amp;lt;FeatureClassDefinitions&amp;gt;() results in the following error message:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier\ new, courier, monospace;"&gt;System.Runtime.InteropServices.COMException: 'Ungültige Klassenzeichenfolge (Ausnahme von HRESULT: 0x800401F3 (CO_E_CLASSSTRING))'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry for the german here, translation is 'Invalid Class String' - HRESULT: 0x800401F3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We assume that it might have something to do with the Utility Network (especially the internal UN Business Tables) which might cause this issue. Retrieving a FeatureDatasetDefinition first is not an option, since a Feature Server does not support that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your suggestions. Would be great if we can resolve that somehow...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Karl&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Feb 2018 16:17:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-sdk-questions/getting-featureclassdefinitions-from-a-feature/m-p/837012#M3610</guid>
      <dc:creator>KarlHuber</dc:creator>
      <dc:date>2018-02-19T16:17:47Z</dc:date>
    </item>
  </channel>
</rss>

