new AddLayersOperationClass error

403
1
02-24-2010 05:19 AM
MartinRivest
New Contributor
Hi,

I try to add a IBaseMapLayer using the sample from the documentation:

IRasterBasemapLayerFactory rasterBMLFactory = new RasterBasemapLayerFactoryClass();
IRasterBasemapLayer rasterBML = rasterBMLFactory.Create(rasterLayer);
ILayer layer = (ILayer)rasterBML;
layer.Name = layer.Name + " Accelerated";
IAddLayersOperation addLayersOp = new AddLayersOperationClass();addLayersOp.SetDestinationInfo(0, map, null);
addLayersOp.AddLayer(layer);
addLayersOp.Name = "Add Accelerated Raster Layer";
IOperation op = addLayersOp as IOperation;
op.Do(); // Add the layer.

But I got an error on creating AddLayersOperationClass: "ClassFactory cannot supply requested class ".

I also try to add the LoadVersion with Desktop and engine before, but I still got the error.

Is there an issue with the class?

I have ArcGIS Dektop / Engine / SDK .NET on my computer.

Thanks

Dominique
0 Kudos
1 Reply
JeremyWright
Esri Regular Contributor
Dominique,

Are you still experiencing this issue?  I was unable to reproduce this issue on current builds of ArcGIS.
0 Kudos