Hot answers tagged

4

It seem you have written an ArcEngine application. So, you must install ArcEngine Runtime on any machine you need to run your application. ArcEngine Runtime is the minimum. You can either install ArcEngine SDK or even ArcGIS Desktop to run you application. The Arc Application (Engine or Desktop), must match the version of sdk that you have built your ...


3

ArcEngine doesn't work like ArcGIS Desktop. If you have the proper licensing for a functionality or extension (e.g. spatial analyst) in ArcEngine, then you can use the related Interfaces of that extension. ILocatorExtension, itself is dedicated to ArcGIS Desktop and can not be used with ArcEngine. With ArcEngine your should utilize : ILocatorWorkspace2 ...


2

You need to point edit to an existing workspace object not the base class. So you need to get a handle on the workspace you intend to edit before you point an IWorkspaceEdit interface to it. Search the API help for the page "Editing with the geodatabase API" there are several code samples to get you going.


2

You can not cast a FeatureClass into a ILayer! Here's the proper way to reach an ILayer from a FeatureClass: .... IFeatureLayer fl = new ESRI.ArcGIS.Carto.FeatureLayer() fl.FeatureClass = FC; var l = fl as ILayer; axMapControl1.AddLayer(l); I am assuming all of your previous methods are correct and you have a valid IFeatuerClass (FC).


1

I have solved this issue now and for those interested, the code is posted below... I help you all find this helpful: public final class ExportLayerToShapefileAction extends SelectionAction { public ExportLayerToShapefileAction() { super("gsExportToShapefile"); } @Override protected void doActionPerformed(ActionEvent e) { IFeatureSelection ...


1

In this case the field NumEvents was not available until the DisplayRelationship was set up. gridLayer = new FeatureLayerClass(); gridLayer.FeatureClass = layersFeatureWorkspace.OpenFeatureClass(layerName); gridLayer.Name = "Density Grid"; gridLayer.Cached = true; gridLayer.Selectable = true; gridLayer.ShowTips = true; [...] // Create relationship between ...


1

Because you have classes that only belong to desktop (IGxDialog, ...), Installation of Desktop is a must do. furthurmore you need an ArcGIS Desktop (engine will not be enough) license to initialize your application. You can do some hacking to pack Desktop dlls with your application, but that is a violation of ESRI terms. Esri indicates that if there are ...


1

Ihad the same problem and I resolved it by casting featureClass from IFeatureClass to FeatureClass: IFeatureClass featureClass = featureWorkspace.openFeatureClass(shapefileName); FeatureClass featureClass2= new FeatureClass(featureClass); ..... //Attempt to acquire an exclusive schema lock on the feature class. ISchemaLock schemaLock = ...


1

One possible work around is to: "create layer from selected features" and label that (maybe making all the geometry transparent). A smart cookie could make a model or add-in to do it.


1

Take a look at the code below. Full code in git repository can be here: https://bitbucket.org/bugramovic/fme_arcobjects_interop_example PrintStream out = System.out; FMEWorkspaceFactory fmeWorkspaceFactory = new FMEWorkspaceFactory(); IPlugInWorkspaceHelper plugInWorkspaceHelper = fmeWorkspaceFactory.openWorkspace( pathToFdlFiles ); ...



Only top voted, non community-wiki answers of a minimum length are eligible