A site-package created by Esri to expose many ArcObjects to Python.

learn more… | top users | synonyms (1)

1
vote
0answers
389 views

Arc10.1: intermittent Error using arcpy.Delete() on temporary rasters

I've been pulling my hair out with an intermittent error when running from either the MS-DOS prompt, PyScripter, or WingIDE. Haven't bothered to check w/in Desktop apps (but a colleague says it's the ...
1
vote
0answers
113 views

Subset a GeoTIFF image into regular grids and extract mean latitude, mean longitude, and mean RGB for each grid

How can I subset a GeoTIFF image with 1000 by 1000 pixels into regular square grids of 50 by 50 pixels (400 grid objects in total); and calculate mean latitude, mean longitude, and mean RGB for each ...
1
vote
0answers
400 views

Python Addin toolbar- Environment mask parameter not being recognised?

I've created a button on a python addin toolbar which uses the selected features from the selected layer in the TOC, creates a feature layer from that selection and uses that feature layer to set the ...
1
vote
0answers
303 views

Problems running zonal statistics - not all zones represented

I have been working on a Python script to automate the steps illustrated by whuber here:Create points around the edge of viewshed results I am trying to create a horizon graph illustrating the ...
1
vote
0answers
317 views

arcpy & TraceGeometricNetwork return ERROR 000584

I am developing a script to automate the creation of a road network following varying criteria. I have created a geometric network and I would like to get the connection between several points with ...
1
vote
0answers
236 views

ArcGIS opposite to pivot table

fellow GIS-ers :)! I've been trying to find a tool to do the opposite to what the "pivot table" tool does but I dont thin there is any tools for that. I have a raster data set derived from Landsat ...
1
vote
0answers
62 views

Are polygons created in Arcpy built in any order?

My script uses a search cursor to evaluate polyline coordinates and build polygons based on those coordinates. The script works well, but I am curious as to whether anyone knows the order (if there ...
1
vote
0answers
489 views

How to transfer the attributes of features based on their spatial relationship?

I'd like to check if a point feature class is placed on a line feature using python in ArcGIS 10.0. I have created a set of point features and placed them directly on a group of line features at ...
1
vote
0answers
497 views

Why does Clip analysis generate (some) empty output?

I am running a script that is working (see below) - it pulls a file from a folder, clips from that file based on an intersection with another file, and creates a new shapefile in a new folder. It has ...
1
vote
0answers
260 views

arcpy ArcGIS Server

Could someone please help me by giving me an example on how to make/connect/Add ArcGIS Server connection via python/arcpy? Thank you in advance. I'm using ArcMap 10.0 I desire to "Use GIS Services" ...
1
vote
0answers
229 views

How to access selected feature attributes using Python Add-in button?

I'm trying to extract the attributes of a selected feature in ArcMap using an add-in button, but I don't know how to refer to this selection in the script. Later I need to copy these attributes into ...
1
vote
0answers
112 views

Is segment of polyline contained in polygon

I am pretty new to arcpy and am slowly learning all its functions. I have a scenario where I am traversing a polyline. I get a start point and an end point on the polyline and form a segment with ...
1
vote
0answers
65 views

Script Tool Problems ArcMap 10.0

I Have a scipt tool that runs when input shape files are added from the table of contents (added from drop down menu.) However this tool will not run when they shape files are added using the add file ...
1
vote
0answers
89 views

Are multiple separate feature classes more efficient than repeatedly deleting all features from the same feature class?

Quick Version: Is it more efficient, in terms of database performance, to have multiple separate temporary feature classes or one feature class that you repeatedly empty out and fill? I am working ...
1
vote
0answers
802 views

ArcPy 10.1 PointGeometry.projectAs()

I'm trying to reproject an X,Y passed in from an Add-in. So far this works fine: pointGeometry = arcpy.PointGeometry(arcpy.Point(x,y),srIn,False, False) projectedPoint = ...
1
vote
0answers
183 views

Table record counts change when using python tool

I have a python tool which investigates mxd files and clips/projects and exports all visible datasets. Recently I've found that the record counts (even on non-clipped data) is different. It's ok if I ...
1
vote
0answers
130 views

jagged edges in mosaic DEM

I encounter edge issues when trying to mosaic USGS NED DEMs in ArcGIS 10.0.0. After projection and aggregation, I attempt arcpy.MosaicToNewRaster_management(). I've reproduced the same results using ...
1
vote
0answers
96 views

Why does the method partCount in ArcGIS always give back a value of 1?

Does anyone knows why method "partCount" in arcgis version 10.0 always gives me back value 1, even when I have object with interniorring or multipart object? partnum = 0 partcount = feat.partCount ...
1
vote
0answers
269 views

Clipping .mdb in place and schema locks

I have an .mdb with a feature class that I want to clip in place - that is, I want to clip it with another polygon, and then store the results back in the original .mdb. I am doing this with arcpy. My ...
1
vote
0answers
634 views

Variable stored as NoneType in Python with updateCursor

SOLVED: although the field was not nullable (no null values), a glitch created one in the heading field, so the variable was stored as a null value and thus the NoneType. I am using updateCursor to ...
1
vote
0answers
193 views

ArcGIS 10.0 - How to have GP Service make rest calls instead of Silverlight client?

I have a Silverlight client that densifies a user drawn polyline. The returned vertices from the polyline are then sent to esri elevation sample server for each vertex to find an elevation value. ...
1
vote
0answers
104 views

Copied points not intersecting the original points

I'm using an arcpy search cursor to access a Oracle database. I have a simple Python class that I copy the returned row objects into, which gives me more flexiblity than the cursor. The problem is ...
1
vote
0answers
91 views

getSelectedExtent not working on joined layers

When joining layers the getSelectedExtent function in ArcPy fails to get the extent. Unjoining the layers and running it yeilds the expected result. The joined layers are all located on an SDE. Is ...
1
vote
0answers
715 views

ArcGIS 10.0/arcpy: Can't retrieve the points in a polyline geometry obect: any idea why?

My arcpy script builds a Python dictionary, dictCLPnts, that holds the geometry objects of a polyline feature class. The following code snippet shows the attempt to access the geometry object with ...
1
vote
0answers
151 views

Arcpy problems regarding convertToMSD() Function

I am having trouble getting the ConvertToMSD Function to work. Technically it works, but not in the long run of my script. I use the converttomsd function to create an msd. I then publish this msd as ...
0
votes
0answers
16 views

Using a Value Table to Calculate Multiple Fields

I'm looking to develop a tool (ideally through model builder as my python writing ability is not stellar) that creates a simple user interface that has dropdown menus for desired fields of a selected ...
0
votes
0answers
11 views

Common Tasks on ArcGIS Server REST service

I have a published REST service with lines in it. If I have the permissions to edit the service in ArcMap, shouldn't I be able to perform a arcpy.Dissolve_management on the lines (client side) to ...
0
votes
0answers
45 views

MS SQL table with geometry field to feature class

I have a table in a native SQL database (no geodatabase, dc_geobank_public.sde in the code) with cca. 300 000 records and 18 fields. Two of the field contains projected X and Y coordinates, and one ...
0
votes
0answers
33 views

Adding Array of strings in File geodatabase feature-class' field

I need to include array type in file geodatabase/shapefile field's content so that when i expose it as a map service, i can get array instead of string or integer. e.g., i got fields: OBJECTID, ...
0
votes
0answers
37 views

Using Arcpy to Update Data Source Does Not Update Related Tables

I have a python script that updates the data source of mxd's from staging to production. Here is an example of the code: import arcpy mxd = arcpy.mapping.MapDocument(r"C:\Project\MyMap.mxd") for lyr ...
0
votes
0answers
13 views

Pythonw has stopped working when running arcpy.SubsetFeatures_ga

I'm currently trying to subset a shapefile into training and validation files. When I run the following line of code, python crashes. I'm using ArcGIS 10.1. arcpy.SubsetFeatures_ga(current_shapefile, ...
0
votes
0answers
22 views

Is it possible to save a dxf in memory

Following on from my question here, when I run the ExportToCAD tool arcpy.ExportCAD_conversion(listOfLayers, formatRelease, location + fileFormat, "Ignore_Filenames_in_Tables", ...
0
votes
0answers
31 views

Consolidating spatial data for nearly 200,000 acre area

more of a broad question here: I'm trying to take a huge amount of spatial data for a specific 200,000 acre area, collected over 15 years dating back to 2000, and organize it. The data layers relate ...
0
votes
0answers
31 views

Summarize an attribute table using python

I am a trying to summarize an attribute table for a dataset that I have. The problem is similar to the one discussed in this question here: ...
0
votes
0answers
20 views

How to `Enable SQL Access` through ArcPy 10.2

I have a multiversion view for a feature class. When I add any field in feature class, it does not reflect on its multiversion view. I have to manually right click on feature class -> Manage ...
0
votes
0answers
42 views

Error in importing arcpy in arcgis python console

I have been coding in eclipse using arcpy 64 bit. the pythonpath in eclipse is set to the 64 bit, the pythonpath in environment variables is also set to the same address. but when I want to improt ...
0
votes
0answers
40 views

After execute arcgis script, what happen with the variables?

After the execution of a Arcgis script (I wrote the script in python language) on a Arcmap session. What happen with the variables that I used in the script? They remain stored somewhere in ArcMap (So ...
0
votes
0answers
50 views

Configuring Python to avoid conflict with ArcGIS for Desktop (ArcPy)?

I am trying to find the best way to configure a new version of python in my computer (windows) so that I do not have any problem with the python version that I have with ArcGIS. Is there anyway to ...
0
votes
0answers
25 views

SQL fails in python. In ArcMap error FDO error: -2147024871 returned

I'm having issues with an SQL expression for a feature class in a file geodatabase. When working in ArcMap, the SQL will fail on its first attempt, and produce the following error: However, when I ...
0
votes
0answers
21 views

Assign a dummy value for removed features in a Polygon-Grid

I want to calculate the entropy index for landuses classes for an area based on a 100m Polygon Grid. I did find an existing toolbox that does all the required calculation. Input features are the 100m ...
0
votes
0answers
21 views

How to align big polygon over smaller ones using ArcPy?

I have to write a python script which is supposed to align an area polygon on the borders of other polygons coming from a cadastral plan. These polygons come from an official source, so they are not ...
0
votes
0answers
17 views

CopyDatasets will not overwrite some datasets

I used a script from esri found here http://support.esri.com/en/knowledgebase/techarticles/detail/40831 to import all the feature datasets and feature classes from one file database to another. In the ...
0
votes
0answers
44 views

ArcPy: execute code for each feature in a dataset

Is there a way in ArcPy to iterate through a dataset and do something with the current feature without having to manually select that feature? Two examples for clarification: - export each feature as ...
0
votes
0answers
59 views

Arcpy strip '{ and ]' from list return

I have a static list that I would like to pull values from and use in a query. I can populate the list dynamically from the data but the set is quite large and I think having a static list from a csv ...
0
votes
0answers
63 views

Error in python code for map automation (loop)

I try to make this code work but I cannot find the error (not very familiar with python) The code should basically run through a file GDB where all the feature classes are stored. It then should ...
0
votes
0answers
36 views

Feature Services & arcpy.ConsolidateMap_management & .replaceDataSource

We have several in house published feature services, including some from our Esri Data Stores. When I use arcpy.ConsolidateMap_management on an mxd (10.1) the Feature Services are nicely consolidated ...
0
votes
0answers
43 views

How to go about buffering different values in a field separately?

I have a clip of urban areas where the names are all messy with hyphens, apostrophe's etc so have decided to use the number value for each name to populate a list. My aim is to do analysis on each ...
0
votes
0answers
15 views

Small individual tables/crosstabs for points from Access to plot on maps

I currently have an Access database (accdb format) that is currently linked in GIS (ArcGIS 10.1) through an OLE DB connection. I have a groundwater analytical table with 36,000+ records that contains ...
0
votes
0answers
77 views

Calculate Lat/Long in decimal degrees

I'm trying to calculate the location of several points in a python script. However, the Add XY tool is in feet, rather than decimal degrees. The following Calculate Field lines just cause an error ...
0
votes
0answers
53 views

Checking for overlaps using python

Trying to write a code where python checks for overlapping polygons within a file geodatabase in the current mxd and basically prints the feature class names overlapping. Here is what i have: import ...