Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Background: I have C#, ArcGIS command that 1. lists selected features, and 2. allows you to delete selected features from this list out of a geodatabase.

My problem: After I delete features, ArcGIS doesn't update the selected features list. When my program asks ArcGIS for the selected features, it gets back references to the features it already deleted. It shouldn't.

My Question: What should I do to tell ArcGIS to check the selected features list for non-existent features? Is there a "refresh" command that will do this, or do I have to reselect the features (excluding the deleted ones) programmatically?

share|improve this question
up vote 3 down vote accepted

Are you in ArcMap? How exactly are you deleting features from the geodatabase? When you use IEditor to do those edits, changes to selection when deleting features should propagate properly.

You might also try casting the Map to ISelectionEvents and calling SelectionChanged to notify of selection change.

share|improve this answer
Thank you for your answer and your good questions. I am in ArcMap. The query is being done via a database connection (OleDbConnection), rather than using IEditor. I would fix it to use IEditor but it would involve a lot of rewiring. I will try your proposed solution. – canisrufus Jul 11 '12 at 16:06
SelectionChanged didn't work for me. What I ultimately did was call Refresh on the SelectionSet object. I'm accepting your answer because it got me on track to a solution. – canisrufus Jul 11 '12 at 20:36

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.