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

I'm trying to follow the Identify snippet from the ESRI ArcEngine SDK

The third line of the tutorial throws a COM exception

public void DoIdentify(ESRI.ArcGIS.Carto.IActiveView activeView, System.Int32 x, System.Int32 y)
  if(activeView == null) return;
  ESRI.ArcGIS.Carto.IMap map = activeView.FocusMap;
  ESRI.ArcGIS.CartoUI.IIdentifyDialog identifyDialog = new ESRI.ArcGIS.CartoUI.IdentifyDialogClass();  //THIS LINE THROWS THE EXCEPTION

{"Retrieving the COM class factory for component with CLSID {F8AAB776-8B1E-11D3-9F7A-00C04F6BC886} failed due to the following error: 80040111 ClassFactory cannot supply requested class (Exception from HRESULT: 0x80040111 (CLASS_E_CLASSNOTAVAILABLE))."}

I expect to run into some trouble using the snippets, but I can't even call a constructor... : (

Any thoughts are appreciated...

specs: ESRI ArcEngine 10 VS 2010 C#

Edit: Maybe I don't have access to the CartoUI library. I also tried this:

AdvancedDrawingDialogClass t = new ESRI.ArcGIS.CartoUI.AdvancedDrawingDialogClass(); 

But I got a similar error.

Edit 2 I found out how to do the identification so I'm going to post it for the community.

for (int i = 0; i < mapControl.LayerCount; i++)
  ILayer layer = mapControl.get_Layer(i);
  if (!(layer is IDynamicLayer))
    ESRI.ArcGIS.Carto.IIdentify identify1 = layer as IIdentify;
    IArray array = identify1.Identify(geometry);
    if (array != null)
      object obj = array.get_Element(0);
      IFeatureIdentifyObj fobj = obj as IFeatureIdentifyObj;
      IRowIdentifyObject irow = fobj as IRowIdentifyObject;
      IFeature feature = irow.Row as IFeature;
      IGeometry geometry1 = feature.Shape; 
share|improve this question
I tried to use the identify UI in arcengine a few years back. Never really figured it out though. – Kirk Kuykendall Jan 17 '11 at 18:08
up vote 3 down vote accepted

It's only available in Desktop and not Engine, according to the API documentation: IdentifyDialog CoClass

share|improve this answer

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.