ArcObjects is a set of COM-based APIs from ESRI Inc. that are used in several of their products including ArcGIS Desktop, ArcGIS Engine and ArcGIS Server.

learn more… | top users | synonyms (3)

68
votes
5answers
10k views

How do I access ArcObjects from Python?

I want to be able to script some things that aren't exposed via arcgisscripting or ArcPy. How do I access ArcObjects from Python? I'm working with ArcGIS Desktop 9.3.1 right now, but will be ...
26
votes
4answers
3k views

Performance of ArcGISScripting and large spatial data sets

I am currently writing a python script using the arcgisscripting module to process a reasonably large data set (~10,000 records in total) normalised over a small number of tables, 8 in total. The ...
5
votes
3answers
2k views

Python, comtypes and ArcObjects: Error creating AppROT object

I am experimenting with comtypes and ArcObjects under Python 2.6.5 and ArcGIS 10 SP1. I'm using the pure Python method to wrap the ArcObjects OLBs described in this answer, but getting an error in the ...
1
vote
2answers
240 views

How to define Subroutines and functions?

I am working in VBA. My error is sub and function are not defined. Here is my code: Private Sub CreateMap(cboDistrict As String) Dim mapDocument As New mapDocument If ...
8
votes
4answers
2k views

Connecting line features and determining the length of the longest line

I have a line feature (see image) representing a river that I created using the Stream_to_Feature tool. The attribute table contains several records representing different lines - the problem is the ...
16
votes
9answers
3k views

Getting started with Arcobjects

What is the best route or place to get started with arcobjects if one is not a developer and not aiming to become a developer? I've been using gis professionally for a long time, almost two decades, ...
12
votes
6answers
3k views

ArcObjects Resources

What are the best books/web sites for C# development with ArcObjects? The ArcGIS Resource Center is very helpful, but I am trying to find sources with more examples. Thanks
3
votes
2answers
954 views

ArcObjects + comtypes at 10.1

Has anyone played around with using ArcObjects in Python at version 10.1? I am having all sorts of problems, such as TypeErrors when wrapping the ESRI OLB modules and AttributeErrors when attempting ...
14
votes
1answer
1k views

Calling arcpy/python from .NET?

Are there any available examples that show how python can be integrated into a .NET ArcGIS Addin or Extension? I have a series of python scripts that I would like to call from form events (e.g. button ...
9
votes
3answers
5k views

How does ArcGIS compute the distance between two points with a non-equidistant projection?

This is a follow-up question to my previous one, Can you suggest some well-written introductory texts about coordinate system projections? Let's assume I'm working with the CH1903 map projection, ...
10
votes
2answers
2k views

Issues with geoprocessing with .NET

There are some nice features in ArcToolbox we can use, but for some reason, this is NOT working properly. It doesn't even throw me an error. My software is running inside ArcMap, so no need to ...
5
votes
3answers
2k views

How to use ArcObjects to choose GeoTransformation?

I’m currently building a Desktop add-in tool with ArcObjects that: Asks a user to select a feature class Reprojects the feature class to Web Mercator Executes some geoprocessing The initial ...
2
votes
2answers
619 views

ArcObjects: Alternative workflow to using a SQL query with over 1000 values in IN statement

I have a ListBox listing the unique values of a column in a feature class; the user can select any number of values and click a button to then zoom to the set of features matching those values. A ...
10
votes
2answers
897 views

How to unit test ArcObjects with Mocking

I'm a huge fan of unit testing, but still make use of a FGDB to grab features for running unit tests against when using the ArcObjects framework. Is anyone successfully using mocking against thinks ...
4
votes
3answers
2k views

ArcMap/ArcObjects - Drawing graphics onscreen: Explanation or tutorial for Draw/Refresh/PartialRefresh methods?

I find myself woefully lacking in understanding of when, why, and how (which type) to do screen draw/refresh/partial refresh. For instance, in a standalone Python script outside the application ...
13
votes
6answers
5k views

Convert between ESRI Geometry and WKT

It seems like there is no means of converting an ArcObjects geometry to the Well-Known Text representation (and vice versa) in ArcGIS ArcObjects API. The only thing I was able to find is conversion to ...
3
votes
1answer
2k views

How do I programmatically create non-feature-linked, simple line callout annotation and set the anchor point?

Vitals: ArcGIS-ArcView 10.0, Python 2.6.5, PythonWin, comtypes I'll start with my main questions: How, using ArcObjects, do I go about creating non-feature-linked geodatabase annotation features ...
5
votes
4answers
340 views

Can I store an ArcObject inside a BLOB or XML field?

I'm having this crazy idea here...Is it possible to store an ESRI object inside a blob field inside a geodatabase? If not, perhaps a serialized XML representation? I'm thinking about storing ...
3
votes
2answers
701 views

Running Arcpy script from ArcObjects

the standard method requires to run arcpy script in commande line, i've struggled with it to run but without a result, i can import arcpy, set the workspace to the geodatabase path and describe the ...
3
votes
1answer
856 views

ESRI Flash Command in custom code

I would like to implement the same flash feature command that ESRI uses when accessing the context menu on a table row. I have used the following successfully to flash a selected feature: ...
3
votes
3answers
2k views

Can you programmatically change the button image for a ESRI.ArcGIS.Desktop.AddIns.Button?

I'm new to the AddIn customization model in ArcGIS 10 and I'm trying to figure out how to change a button image for a button. I'm looking for the equivalent to the BaseCommand UpdateBitmap method and ...
9
votes
1answer
569 views

Arcobjects in Python: assign interface to objects with feature (shape) geometry

I am trying to use ArcObject in Python. I do have problem with assigning an interface (i.e. IZ.InterpolateZsBetween) to my object with geometry data, code is: from Comtypes.client import ...
2
votes
2answers
525 views

Create layer from in-memory shape data

In my current project, a feature layer is created based on shape data generated after some complicated surface analysis procedure. The sequence right now is like [Surface Analysis Algorithm] -> ...
13
votes
2answers
2k views

How can I create weighted Thiessen polygons?

I have a point shape file and I create Thiessen (Voronoi) polygons programmatically using this scripting syntax: CreateThiessenPolygons_analysis (in_features, out_feature_class, fields_to_copy) ...
14
votes
3answers
917 views

Algorithm to find out points of inflection for a polyline

I am trying to find out the points of inflection , i.e. points where the curves in a line start and end. If you look at the image, the green line may be a road or a stream, and the black points are ...
14
votes
3answers
2k views

ArcObjects: Memory leak in IFeatureClass.Search (only on SDE with direct connect)

UPDATE 6/30/11: ESRI Support say they have reproduced the issue and have opened a bug report (NIM070156). I have determined that there is a memory leak (in unmanaged heap memory) that occurs when a ...
4
votes
4answers
1k views

Exploring ArcObjects through C# or VB from Python background

While I understand that this may be off topic to an extent, I am in a bit of a bind and could use some help directing my thought process and research. I have little programming background aside ...
3
votes
2answers
3k views

Remove lock on feature class

When i try to delete a feature class , after or during the use of an Arcgis engine app which uses the same feature class i got an error concerning the lock , so i can't get ride of this lock until i ...
6
votes
4answers
2k views

Programmatically edit/update metadata in ArcGIS 10

Has anyone succeeded in programmatically updating metadata in ArcGIS 10? Considering using Python/arcpy but ArcObjects (C# or Python/comtypes) is also a possibility. I need to update both the FGDC ...
5
votes
2answers
246 views

Near analysis with mixed feature types in ArcObjects

I am trying to emulate the Near (analysis) ArcGIS tool in ArcObjects. http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//00080000001q000000 I want to use Mixed Feature Types. I have a ...
2
votes
3answers
3k views

Streetview/Bing Bird's Eye Add-In

I'm trying to create an Add-In for this tool: Link to Google Maps and Bing from MXD (Streetview and Bird's Eye supported) I'm not receiving an error however my browser is not opening after I select ...
2
votes
3answers
1k views

Export a join table to arcmap

I have shape file (Point) and a table which I join using the following code. public ITable JoinLayer_Table(IFeatureLayer pFeatLayer, IStandaloneTable pStTable) { IDisplayTable ...
13
votes
5answers
2k views

Is Hillshade option in ArcMap rubbish or is it me?

Here is a pretty pic of the raster I am using - with no effects applied - just the color ramp and historgram adjusted to show out all the relief - all be it in a very 2D way! I have a raster layer ...
8
votes
4answers
5k views

How do I cleanly uninstall ArcGIS 9.3.1 extensions after ArcGIS 9.3.1 is uninstalled?

I uninstalled ArcGIS 9.3.1 (server, desktop, engine), then installed ArcGIS10.0 (Server, Desktop, engine). When I tried to uninstall some arcmap extensions, I got error 1001 "unable to get installer ...
3
votes
2answers
292 views

Listing features in the order they were selected

This is an ArcObjects-specific version of this question: Create Array From Selected Features Based on the Order in Which They Were Selected Is there a way to get the selected FIDs of a feature layer, ...
3
votes
2answers
411 views

Cannot persist to a blob field

Following this initial thread I'm having some problems implementing what was suggested here: Can I Store An ArcObject inside a BLOB? Well, following the link Kirk provided, I've came up with this: ...
3
votes
2answers
192 views

How can I implement Persistance in a Layer Extension?

Last time I checked, arcgis doesn't honor IPersistVariant in layer extensions. Rather advanced code has been provided here showing how to implement IPersistStream. Is there something simpler?
3
votes
2answers
918 views

Accessing ArcGIS layers from seperate thread

I've got an ArcEngine application, referencing a MXD for it's data (and map display). I'm running a query against all layers, so can take quite some time. I would normally run the query in a ...
2
votes
4answers
807 views

How to distinguish between File and Personal Geodb workspace?

I am looking for a way - given an IWorkspace object - to check if it was created from a Personal-GDB or a File-GDB. I tried using IWorkspace.WorkspaceFactory to check if it's an instance of e.g. ...
1
vote
1answer
751 views

Is there any way to set polygon features fill color and outline programmatically?

By some process I am creating a polygon feature layer. Before adding the layer in the map, I want to set polygon's fill color to no color and set polygon's outline color and width. I am working with ...
8
votes
3answers
7k views

How to create a button in Arcmap 10 to run a Python program?

I have a script that I want to run within ArcMap when a button in a toolbar is clicked, and so far I have only been able to make the script into a script tool. I need it to run as a command, not as a ...
6
votes
1answer
353 views

Why are annotation features containing both GraphicElement and TextElement objects not drawing in an ArcGIS Server map service?

I am building annotation features with Python/comtypes/ArcObjects. The annotation works great in ArcMap (10.1), but it is does not draw when published to a map service in ArcGIS Server. Each piece ...
6
votes
1answer
2k views

First attempt using ArcObjects: ESRI's Add-ins example unclear

I've come to realize that scripting ArcGIS 10.0 with Python imposes too many limitations for my goals with ArcGIS, so I've decided to bite the bullet and delve into ArcObjects. Apparently, using ...
5
votes
2answers
2k views

How to catch when scale is changed in ArcGIS?

We want to update a combobox so that it always shows the correct scale. If the user zooms-in, out or resizes the control hosting the map. What is the best event or events to catch and use in ArcGIS to ...
4
votes
4answers
2k views

Determine overlapping points using a spatial filter in ArcObject

I have a point layer with thousands of points. Using a spatial filter, I have to find out those points which are intersecting each other. Then the objectid's of the intersecting points should be ...
4
votes
4answers
4k views

How do I remove Schema Locks from a File GeoDatabase in Java in ArcGis 9.3?

I have an application written in Java which uses ArcObjects 9.3. The application accesses a file GeoDatabase. The application produces output in the GeoDatabase that will be accessed by ArcMap. The ...
3
votes
0answers
104 views

How to compute surface of raster or any point using ARCGIS?

I have a raster image whose values are a digital elevation model of terrain. I need to know the surface type (topographic characterization) of particular points along transects of this DEM. How to ...
3
votes
2answers
482 views

How to find self-intersecting polylines using ArcObjects?

If I have a polyline, how do I figure out whether it is self-intersecting? I tried to use ITopologicalOperator.IsSimple Property, but it always returns true. Are there any ways of doing these kind ...
3
votes
2answers
427 views

Using ArcObjects, how to convert an Access table into a proper geodatabase table?

I have inherited an ArcGIS application that creates a number of access database tables. I'd like to use ArcObjects to convert them to proper geodatabase tables, which I understand to mean simply ...
3
votes
3answers
671 views

How do I convert existing fields to lat and long using the Calculate Field tool?

I am trying to convert my X and Y fields from feet to lat and long. I can easily do this in Calculate Geometry from the attribute table, but I'm needing to use this in a model and Calculate Geometry ...