<?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: ISpatialFilter SpatialRelDescription find points not in polygon in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40447#M1051</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks again Neil,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am doing it on the featureclass level to delete unwanted points in the featureclass and I have some attribute criteria along with the spatial constraints.&amp;nbsp; The code is called inside of arcmap but also in an exe.&amp;nbsp; Reversing the selection would mean also reversing my attribute query.&amp;nbsp; There shouldn't be more than a few hundred points meeting the attribute constraint, so I think I will just use the Irelationaloperator.disjoint on each point.&amp;nbsp; Not the most efficient but probably easier to support in the long term.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I just find it annoying that the spatialfilter spatial relationship enum is very limited and the shape comparison language is poorly implemented.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 19 Jan 2012 14:01:28 GMT</pubDate>
    <dc:creator>AlexanderGray</dc:creator>
    <dc:date>2012-01-19T14:01:28Z</dc:date>
    <item>
      <title>ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40443#M1047</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi there,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a point featureclass (not M or Z aware) and a polygon.&amp;nbsp; I want to use a spatial query to find all the points not in the polygon.&amp;nbsp; As far as I can tell only the spatialRelDescription will do this.&amp;nbsp; The problem is I get inconsistent results.&amp;nbsp; Some points are found as expected other are not.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I used the following string:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;"F********"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;"******T**"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It finds some of the points but never all of the points.&amp;nbsp; I am somewhat perplexed.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The alternative is to loop through all the point and use a relational operator but that seems like it would be slower.&amp;nbsp; The SpatialRelDescription should work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jan 2012 12:57:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40443#M1047</guid>
      <dc:creator>AlexanderGray</dc:creator>
      <dc:date>2012-01-19T12:57:46Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40444#M1048</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Do the search geometry and the featureclass have the same spatial reference?&amp;nbsp; If not, you'll need to project the search geometry into the same spatial reference as the featureclass you're searching.&amp;nbsp; Alternately, you can set the OutputSpatialReference property on the spatial filter object.&amp;nbsp; Trying to set the description string can be confusing and there have been bugs found in the past, so you may ultimately have to log an incident with ESRI to get to the bottom of it.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jan 2012 13:19:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40444#M1048</guid>
      <dc:creator>NeilClemmons</dc:creator>
      <dc:date>2012-01-19T13:19:16Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40445#M1049</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Neil,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The polygon and featureclass both have the same spatial reference which is a custom polar stereographic.&amp;nbsp; I have had a bad experience going to esri support about the spatialreldescription in the past.&amp;nbsp; I was told that their topologist had just left and they were waiting to get a new one to fix the problem, later the issue was closed because they refused to acknowledge that the behaviour of the method was incorrect.&amp;nbsp; To be honest I think the help on the subject is really poor, so I often have a hard time figuring out if my strings are correct in the first place.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jan 2012 13:41:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40445#M1049</guid>
      <dc:creator>AlexanderGray</dc:creator>
      <dc:date>2012-01-19T13:41:27Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40446#M1050</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Thanks Neil,&lt;BR /&gt;&lt;BR /&gt;To be honest I think the help on the subject is really poor, so I often have a hard time figuring out if my strings are correct in the first place.&lt;BR /&gt;&lt;BR /&gt;Cheers&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;That's the problem I've had when trying to use it.&amp;nbsp; One thing you might try is to use IFeatureSelection to select the points you want.&amp;nbsp; Call SelectFeatures once to select all features then call it again to subtract the points inside the polygon.&amp;nbsp; It will be slower than using a single query but it should work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jan 2012 13:51:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40446#M1050</guid>
      <dc:creator>NeilClemmons</dc:creator>
      <dc:date>2012-01-19T13:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40447#M1051</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks again Neil,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am doing it on the featureclass level to delete unwanted points in the featureclass and I have some attribute criteria along with the spatial constraints.&amp;nbsp; The code is called inside of arcmap but also in an exe.&amp;nbsp; Reversing the selection would mean also reversing my attribute query.&amp;nbsp; There shouldn't be more than a few hundred points meeting the attribute constraint, so I think I will just use the Irelationaloperator.disjoint on each point.&amp;nbsp; Not the most efficient but probably easier to support in the long term.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I just find it annoying that the spatialfilter spatial relationship enum is very limited and the shape comparison language is poorly implemented.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Jan 2012 14:01:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40447#M1051</guid>
      <dc:creator>AlexanderGray</dc:creator>
      <dc:date>2012-01-19T14:01:28Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40448#M1052</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;What version of ArcGIS are you using? There is a bug in spatialRelDescription at 10.0 that is fixed in 10.0 sp4.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Jan 2012 14:31:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40448#M1052</guid>
      <dc:creator>LanceShipman</dc:creator>
      <dc:date>2012-01-23T14:31:38Z</dc:date>
    </item>
    <item>
      <title>Re: ISpatialFilter SpatialRelDescription find points not in polygon</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40449#M1053</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am using SP2.&amp;nbsp; I am probably going to be stuck at SP2 for a long time because NIM074169 has been declined, the solution being: "&lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;Use SP2&lt;/SPAN&gt;&lt;SPAN&gt;".&amp;nbsp; I hope this is not the solution for 10.1 or we will be permanently stuck and 10.0 SP2.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://support.esri.com/en/bugs/nimbus/TklNMDc0MTY5"&gt;http://support.esri.com/en/bugs/nimbus/TklNMDc0MTY5&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Jan 2012 15:06:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/ispatialfilter-spatialreldescription-find-points/m-p/40449#M1053</guid>
      <dc:creator>AlexanderGray</dc:creator>
      <dc:date>2012-01-23T15:06:15Z</dc:date>
    </item>
  </channel>
</rss>

