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

ArcObjects SDK for .NET and ArcGIS 10 Desktop

Quick snippet to set the stage:

IEditor3 editor.StartOperation();  
IFeature newFeature;
// fill out newFeature.Shape, etc.
editor.StopOperation("Adding new feature");

At this point I'd like to automatically "show" the attributes for this new feature in the Attribute display/table, which could be visible alongside the Create Features template list.

Equivalent process through ArcMap itself:

  • Start the Editor via the Editor Toolbar.
  • Click a feature template from the Create Features list.
  • Click the Attributes button to open the Attributes display.
  • Mouse-down in ArcMap. See new/default attributes for the new feature be displayed in the Attributes table area.

Is the possible with ArcObjects for .NET?

share|improve this question
up vote 5 down vote accepted

You can execute the command to show the window yourself as in the code below:

    var document = _app.Document;  // _app is an IApplication reference
    var uid = new UIDClass { Value = "esriEditor.AttributionCommand" };
    var item = document.CommandBars.Find(uid, false, false);


Edit: then, to view the feature in the Attributes window, you would add it to its layer selection set (via the layer's IFeatureSelection interface). You will also need to notify ArcMap about the selection change - call IFeatureSelection.SelectionChanged, followed by ISelectionEvents.SelectionChanged (you would obtain ISelectionEvents by casting from the Map class).

share|improve this answer
k. Interesting, thank you, that does in fact show the Attribute window. However, what is more important to me is displaying or refreshing to that window any/all attributes of this newly created feature at the point of its creation (i.e. FID, OBJECTID, other attribute categories, etc.) – Josh Oct 13 '10 at 17:24
@Josh: you will need to add the new feature to the selection, see my edit. – Petr Krebs Oct 13 '10 at 17:37
Ah right, because a new feature immediately becomes selected (or supposed to anyway). That's it exactly. @petr k., many thanks. – Josh Oct 13 '10 at 18:24

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.