<?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 C# Arcgis client - how to create spatial set to add to Map objects in Developers Questions</title>
    <link>https://community.esri.com/t5/developers-questions/c-arcgis-client-how-to-create-spatial-set-to-add/m-p/7477#M49</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have worked with such languages as Python when dealing with ESRI geometries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I have now been asked to amend some C# to add a group of simple line geometries (straight lines) to a map, sourced from a soatial SQL table. We only seem to have ArcGIS Client available and I don't know where to start.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will try and explain the issue as carefully as I can.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We have a SQL Server spatial table called DP_Accesses that, in simple terms, has a unique key and a geometry of LineString e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; APID - char(18)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Shape - geometry of LineString&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is itself a huge table with about 30 million rows&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have managed to build a list of APID values in C# that I want to use to select rows from this table and add to my map. However, please note that this could be a list of anything from 1 to about 7000 APID values, so in itself it is not a small list&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As I am at a point where I have completed this list of APID values, how do I create the layer/spatial collection that can be added to the map, using the ARCGIS Client functionality in C#? I am on .Net Framework 4&amp;nbsp; and using ARCGIS 10.2 Client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 29 Oct 2015 16:33:16 GMT</pubDate>
    <dc:creator>MarkWingfield</dc:creator>
    <dc:date>2015-10-29T16:33:16Z</dc:date>
    <item>
      <title>C# Arcgis client - how to create spatial set to add to Map objects</title>
      <link>https://community.esri.com/t5/developers-questions/c-arcgis-client-how-to-create-spatial-set-to-add/m-p/7477#M49</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have worked with such languages as Python when dealing with ESRI geometries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I have now been asked to amend some C# to add a group of simple line geometries (straight lines) to a map, sourced from a soatial SQL table. We only seem to have ArcGIS Client available and I don't know where to start.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will try and explain the issue as carefully as I can.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We have a SQL Server spatial table called DP_Accesses that, in simple terms, has a unique key and a geometry of LineString e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; APID - char(18)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Shape - geometry of LineString&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is itself a huge table with about 30 million rows&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have managed to build a list of APID values in C# that I want to use to select rows from this table and add to my map. However, please note that this could be a list of anything from 1 to about 7000 APID values, so in itself it is not a small list&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As I am at a point where I have completed this list of APID values, how do I create the layer/spatial collection that can be added to the map, using the ARCGIS Client functionality in C#? I am on .Net Framework 4&amp;nbsp; and using ARCGIS 10.2 Client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mark&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Oct 2015 16:33:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/c-arcgis-client-how-to-create-spatial-set-to-add/m-p/7477#M49</guid>
      <dc:creator>MarkWingfield</dc:creator>
      <dc:date>2015-10-29T16:33:16Z</dc:date>
    </item>
  </channel>
</rss>

