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

learn more… | top users | synonyms (1)

0
votes
1answer
18 views

Appending feature classes from one geodatabase to another geodatabase for python

I am attempting to write a stand alone python script which will loop through the first GDB and append each feature class to its corresponding feature class in the second GDB. The error code that I ...
1
vote
1answer
18 views

Use updatcursor to replace values in multiple fields

I have spent a couple days digging through forums here, ESRI help and elsewhere and each variation of the codes I have tried has not worked. As best as I can tell this is due to my attempt to loop ...
1
vote
1answer
5 views

add-in to open automatically "data frame properties

How can created an ArcMap Python add-in using ArcGIS 10.1 to open automatically data frame properties And change the background color of another?
2
votes
0answers
15 views

Get value from Metadata in Python Script for attribute

I am working on a python script to create some feature classes from dbf tables. As part of the script I would like to pull two values (FGDC "publication date" and ArcGIS Spatial Reference ArcGIS ...
1
vote
2answers
54 views

Calculate Fields with Null Values using the data update cursor using ArcGIS 10.1 sp 1

How do you calculate fields with null values? I have multiple fields that may have null values, that aren't being calculated in the third field. import arcpy with ...
2
votes
0answers
16 views

How do you perform the equivalent of the Esri Identity_analysis (line with poly) with PostGIS?

I've got a section of arcpy code that I need to port PostGIS: Identity_analysis with the in_features being a line featureclass and the identity_features being a polygon featureclass. I'm primarily ...
2
votes
1answer
38 views

How to extract polygons from a road network?

I need to extract faces (or polygons) from my road network and calculate their areas. I mainly use Arcpy packages but even if you know it in QGIS APIs, I'd appreciate if you'd share it with me. If it ...
1
vote
1answer
17 views

Issues with FME and the ArcInfo licence

I have ArcInfo 10.2.1, Python 2.7 and FME 2013 SP4 installed on my Computer. I want to run a python script I exported from ModelBuilder (where it ran without issues) and imported in FME as shutdown ...
1
vote
2answers
27 views

How to provide a default value in an arcpy script?

How do I provide a default value like recommended in every Arcpy script? This script is exported from ModelBuilder where every output except the last one is set to temporary and managed. I want this ...
0
votes
1answer
9 views

buffer by objectid in arcpy

is there a way in Arcpy (arcgis 10.2.1) to buffer lines by selecting thier objectid? arcpy.Buffer_analysis("MY_JUNK","d:/data/ArcGIS/Default.gdb/MY_JUNK_Buffer1","10 ...
0
votes
1answer
7 views

ERROR 000539: Error running expression_NameError: name 'shape title' is not defined

I'm trying to get the title of the shapefiles or feature classes that are in a workspace (folder or GDB), into the field as a Name in python. I know this is easier in modelbuilder by adding %Name% in ...
1
vote
1answer
18 views

How to Set Label Expression Using a Long Field Type in Toolbox

What I am hoping to be able to achieve with this Tool within my Toolbox is to allow the user to input a number of layers and to set all of the labels with the same font settings (font style, color, ...
0
votes
2answers
42 views

arcpy calculate string field: Any ideas what how to fix this?

I'm trying to store a string value obtained from a loop through a tuple into a field called ROW_1. The code goes like this: for creekclass in listOfClassTuples: (classname, Permanency, ...
2
votes
1answer
41 views

How can you alter label styles (font, color, size, etc.) using Python scripting? (ArcGIS 10.2)

I am trying to write a python macro that will automate the process of labeling points in a layer based on different types of apartments. For example, one style of apartments would have a blue square ...
0
votes
0answers
24 views

mxd.saveACopy(outMxd) not working

Getting an intermittent error. I'm opening an MXD, modifying, and then trying to save out with a new name. I think it's because the output MXD name is similar to the input MXD name. Note that I ...
2
votes
2answers
38 views

Python Tool Not Opening

I know that this is definitely an ambiguous question. However, I initially had my Python toolbox working great. I then wanted to have additional functionality with it and added some more coding. ...
0
votes
0answers
31 views

Facing difficulty in saving an output to CSV [on hold]

After implementing the code published by Jason in this answer to How to list feature classes in multiple geodatabases in a folder?, I have received an output like this: ...
0
votes
1answer
41 views

Avoiding ImportError: No module named numpy?

When I try to import ArcPy, I get the following message. Any help would be appreciated.
3
votes
4answers
272 views

Having trouble with 'and' 'or' statements and negative numbers

I have set up a program that calculates the relationship between a point and the first point of a polyline. The aim of the program is to run this calculation and then copy the result to a certain ...
0
votes
1answer
115 views

Python in ArcGis, cannot find what is wrong with my syntax

I am using Feature class to Feature class to batch convert some .dwg files. However python does not like the last statement (name). It's probably something very simple, any idea where I'm going ...
2
votes
2answers
28 views

Preventing ArcPy from changing MXD extent?

I want to process mxd datasources without changing the extent. When I open the MXD in ArcMap and click full extent, I get 1:214,890, after I save and re-open in ArcMap I get what I saved with. ...
1
vote
0answers
12 views

Kriging Interpolation of Daily rainfall data using ArcPy?

I want to perform the interpolation of daily rainfall data for 7 years. I am now working on python using arcpy module. I face several problems while performing interpolation Some day there is no ...
1
vote
0answers
11 views

Error 000725 importing Python (Arcpy) script into tool of standard toolbox? [duplicate]

I have created a Python script. When I run the script as a standalone by make this a hard set path instead of sys.argv1, the script really runs fine. When I import this script as a python tool box ...
5
votes
1answer
33 views

PySAL natural breaks from Numpy array

I am attempting to extract natural break values from a raster using Python. The intended process goes: Arcpy raster object to NumPy Array (using RasterToNumPyArray) to natural break values (using ...
1
vote
1answer
11 views

Including NoData zones in zonal statistics table

I am running the zonal statistic tool on a raster with a shapefile that consists of several regional polygons. I would like the zonal statistic to include the regions that are completely NoData in the ...
1
vote
1answer
16 views

Changing order of parts in multipart geometry using ArcGIS for Desktop (or ArcPy)?

Is it possible in ArcGIS to change order of the parts in multipart geometry? In the context menu i founded "insert before" , "insert after" but it never comes active ... or is it possible via ...
1
vote
0answers
22 views

User input and passing variables with ModelBuilder

I have created three modelbuilder tools that must be run in sequence. After running each tool, the user must examine several shapefiles and potentially change the input parameters of the next tool. ...
1
vote
2answers
45 views

Select points within a polygon and update attributes

This seems really simple but I can't get it to work. I have two feature classes, a polygon of sales areas for a city, and point layer of addresses. I want to select the addresses based on the sales ...
-3
votes
0answers
31 views

Exporting group layers from Table of Contents (TOC) to Folders of shapefiles?

I have some group layers in the Table of Contents (TOC). Each group of layers references a few shapefiles from different source folders. I would like to export each group layer name as a folder and ...
-2
votes
1answer
51 views

Exporting file geodatabase (GDB) to Folder of shapefiles?

I have a geodatabase with several feature dataset and feature classes associated with it. I want to export each feature dataset as folder and feature classes associated with each feature dataset will ...
1
vote
1answer
51 views

Importing file geodatabase (GDB) to table of contents (TOC) of ArcMap?

I have a geodatabase with several feature dataset and feature classes associated with it respectively. I would like to create a .mxd where the Table of contents consist of group layer and each group ...
1
vote
0answers
36 views

ArcPy on 64 bit Windows [duplicate]

I can't import arcpy into 64 bit Python. It works just fine in the python install from arcGIS, though. When I try to import it elsewhere, I get this error: Traceback (most recent call last): File ...
0
votes
0answers
21 views

PythonWin Debugging

My question is theoretical. I want to debug my script in Pythonwin. Everything is OK when I run my script normally (without debugging) but if I am debugging it, my script fails when it tries to read a ...
1
vote
1answer
37 views

Export Multiple Raster Data with custom Cell Size

I Have 172 Raster, and need to change the cellsize. So I use Export Data from TOC and change the cellsize manually (example I want to change it to "3") I tried using this python script to ...
1
vote
3answers
70 views

polygons to polygon conversion with attribute name [duplicate]

1) I have a polygon shapefile with 1000 multi-part polygons in it. Each Row of the table is a multipart polygon. 2) I need 1000 shapefiles with 1 multi-part polygon in each. 3) Each output shapefile ...
2
votes
1answer
56 views

ListRasters based on filename using Arcpy

I am trying to create a python script for ArcMap which calculates the ndvi from two raster images for each RGB/NIR pair in a folder. However, I am unsure how to create two raster lists; one which ...
3
votes
1answer
20 views

Accept multiple input types in ArcGIS Script Tools UI

everyone! I'm working on a python script that calculates aggregations of ACS Variables (i.e. adding "Renters who spend more than 30% of Annual Income on Rent", "...40%...", "...50%...", etc.). The ...
1
vote
1answer
35 views

How to generate a choice list (dropdown) in a toolbox that will allow the user to select a field in a csv as input?

I need to input a csv as parameter 1. Parameter 2 should be a dropdown displaying the various fields (the headerline) where I can select a column to use for geoprocessing. Param1: c:\my.csv ...
1
vote
1answer
37 views

How to ascertain if a cell/field contains a value in ArcGIS attribute table

I have done a bit of research on this but can't seem to find an answer. I am wondering if there is a way to identify whether a cell/field in the ArcGIS attribute table contains a value using the ...
0
votes
0answers
60 views

Looping through each specified layer and exporting PDF map showing shapefile and information taken from each attribute table?

I have been working on an automation script for the purpose of mass pdf exportmaps. I am required to export many pdf maps showing individual boundary files and client information. I believe the ...
2
votes
1answer
49 views

How to check shape length before running code in Python/ArcPy?

I am using a code to convert a polygon into evenly spaced parallel lines for point in range(0,numPoints+1): shortPoint1 = currentLines[firstLong].positionAlongLine(lineSpaceNum*point) ...
2
votes
1answer
30 views

How to create Multipart Line in ArcPy?

I am developing some script in where I want to create custom multi part line geometry. For example: I have one array of points a,b,c and second array of points e,d,f. I want to create one ...
0
votes
2answers
35 views

problem with csv.writer output Python 2.7 [closed]

I cobbled together a script from hacked bits around the net that works pretty darned well except..... The screen return is perfect but the csv contents (filename and path) have deliminators in them. ...
0
votes
0answers
43 views

Exporting table of contents (TOC) with group layers to file geodatabase (GDB) with feature datasets?

I have created a python code for exporting shapefiles from TOC from different source folder to a output folder. However, in this case, I have some group layers in the Table of Contents (TOC). ...
1
vote
1answer
45 views

Listing all feature datasets and classes from multiple geodatabase into CSV file? [duplicate]

I have a folder having multiple geodatabase and I am calling that folder “Multiplegdb” There are 3 geodatabase in a folder which are as follows: ABC.gdb UVW.gdb XYZ.gdb Each geodatabase have ...
1
vote
1answer
20 views

Batch processing of geodatabases - join raster with table

I am unsure how to go about doing this using Python in ArcMap, though I know how to do it by hand. I have geodatabases containing gSSURGO data, one for each state, in their own folders. I have a ...
0
votes
1answer
24 views

Joining rainfall data to point features using ArcPy?

I have 180 point feature classes with rainfall totals. Each feature class represents one days rainfall for a region and has around 36K points (think of each point as a weather station in the region). ...
-3
votes
0answers
26 views

Transformation of Feature dataset list [closed]

I have a input.CSV file and first column consists list of feature dataset and input.csv consist of 5 rows and 1 column. EMI_EMF Cultural Resources Hazardous Materials Parcels Footprints Now I ...
1
vote
1answer
31 views

Creating multiple Feature Datasets from table/list using ArcPy?

How to Create multiple Feature Datasets from a table/list. I can create a single feature dataset in a geodatabase with this python code. import arcpy from arcpy import env env.workspace = ...
-4
votes
0answers
24 views

geographic information systems parcels automation [closed]

I need a python script to automate a workflow. I have a parcel feature class that i receive information from planning and also from county. I only want to extract certain fields from each entity. ...