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

learn more… | top users | synonyms (1)

0
votes
1answer
14 views

Auto adding map elements using ArcPy? [closed]

I am very new with Python scripting in ArcGIS Desktop. Just wondering if there is a way to auto add in map elements?
0
votes
1answer
24 views

Valid input for ArcPy raster to polygon in 10.1?

I'm experiencing some strange problems with this code starting from files with *.tif.tif to what seems should be *.tif.tif.shp according to the code. The code is not working because of the ...
0
votes
1answer
24 views

When using “arcpy.gp.Int_sa” in Arcmap 10.1, what do I need to import?

My Arcpy code is not working because an error with the last line: Error 000824: The tool is not licensed. I have all my extensions turned on, so I don't know why I would be getting this error. It ...
0
votes
1answer
96 views

Using Python script tool in ModelBuilder?

i have created the following tool to add two fields in a table and do a calculation in order to put the tool to ModelBuilder. For some reason when i am going to put it as an input in an another tool ...
0
votes
2answers
39 views

Geoprocessing tool default path access every one?

I am using Geoprocessing tools i have face one problem with default gdb access in my system (default gdb means C:\Documents and Settings\\My Documents\ArcGIS\Default.gdb ) how can access different ...
0
votes
1answer
22 views

Debugging AttributeError: 'Result' object has no attribute 'save' from ArcPy script?

I Keep getting this error message when i run the code below, can anyone tell me why? Error message: Traceback (most recent call last): File ...
1
vote
1answer
26 views

How apply error messages to a python toolbox that prevent my tool from running with bad parameters?

This is a continuation of my question here: Point and Polyline I tried making this question easier to follow. My tool accepts two main parameters - a continuous centerline and a table (or a feature ...
-1
votes
1answer
32 views

I want to reclassify a raster in one folder, rename it and put it in new folder using Python

I've been combing stack exchange and I cannot figure it out. I have a raster "slope_tif_18TXK030910", I want to reclassify it, rename it and put it into a new folder. this is what I have and it works ...
-2
votes
0answers
12 views

Cannot assign name to resultant terrain using ArcPy so cannot save result? (posted again) [duplicate]

Question of python in ArcGIS: I can not assign a name to the resultant terrain, thus I can not save the result. I'm new to arcpy. By a piece of script using SetNull() in Raster Calculator, I want to ...
1
vote
0answers
19 views

ArcPy arcpy.gp.ExportMapServerCache invokes error: A secure connection with this site cannot be verified

What worked last week on many computers no longer works this week. My great ArcPy script gets a users current display extent and invokes gp.ExportMapServerCache to copy a web cache locally. It was ...
0
votes
0answers
26 views

UpdateLayer & ApplySymbologyFromLayer_management doesn't seem to be working

I have been trying to update the symbology of my raster layer file but nothing is happening. I don't get any error messages from using updateLayer or ApplySymbologyFromLayer. It also printed ...
-1
votes
0answers
41 views

Add layer label using ArcPy

I want to show 'ID' of each polygon in a shapefile using arcpy in data view mode. It should be fairly simple but not been able to figure it out. Any lead would be helpful. mxd = ...
0
votes
0answers
35 views

Why do Python scripts on scheduled task fail intermittently with various exceptions? [closed]

I have several Python scripts which are set on a task scheduler to run around 7 or 8 times a day between the hours of 1:30PM-5:30PM every half hour. The output from the script is an email with the ...
0
votes
1answer
32 views

Populating an attribute inside a loop

New to python scripting. One of the issues I have been working on is trying to get a script to calculate the elevation gained in each stream section based on a single input and the knowledge of the ...
1
vote
1answer
24 views

Loop through multi-input list/selection?

I'm back with a script I've previously posted about that I'm constantly improving. Below is a working script that is connected to a database with 52 feature classes on a server that, when having user ...
0
votes
1answer
53 views

pythonaddins module

I've posted this question on GeoNet 4 days ago. At the moment I've received no answers and no comments so I thought I'd try here as well. https://geonet.esri.com/activity#nPLoc=/inbox I have a tool ...
0
votes
1answer
33 views

How to convert date field value returned by REST API to correct date? [closed]

I performed a query on this USGS feature service of Airport locations: Click for query And the value for the field LOADDATE is: LOADDATE: 1411380301000 However, when I pull the layer into ArcMap, ...
2
votes
1answer
118 views

Using Python to select random location from shapefile?

I have multiple shapefiles with bars names and location attributes and I want to create a script which asks the user for the area or shapefile name where they want to go and then prints a random ...
2
votes
1answer
19 views

Creating PolylineZ in arcpy

The script below is slightly modified "Polyline example" from ArcGIS help http://resources.arcgis.com/en/help/main/10.1/index.html#//018z00000008000000 import arcpy # next 3 lines are new from arcpy ...
0
votes
1answer
47 views

How to get arcpy to access attributes of a geometry?

As a novice python programmer I am struggling mightily with my code. What it is supposed to do is Buffer a bunch of points with four distances (100, 200, 300, 400meters) Calculate zonal sum for ...
0
votes
1answer
20 views

Batch reclassifying rasters in folder using ArcPy?

I am very new to python. I am using ArcGIS 10.0. I am trying to batch reclassify rasters in a folder and put the outputs into the same folder but with a new name(trying to do this using outputPrefix). ...
-1
votes
1answer
18 views

Load multiple layers into multiple maps - python

import arcpy import arcpy.mapping import os import sys from arcpy import env #import string env.workspace = r"G:\GIS" mxds = arcpy.ListFiles("*.mxd") lyrs = arcpy.ListFiles("*.lyr") for maps in ...
2
votes
0answers
20 views

Converting points using FeatureClassToNumPyArray to interpolate cross-section with scipy “interpolate” [closed]

I'm trying to plot elevation cross section and extract elevations along a cross section using scipy's "interpolate" function. I'm converting a point feature class of profile elevation points to 2 ...
-2
votes
1answer
26 views

Python Graduated Symbols [closed]

I am currently struggling with creating graduated symbols via Python. Based on ArcGISHelp 10.1 - GraduatedSymbolsSymbology (arcpy.mapping) I am doing as follows: import arcpy mxd = ...
0
votes
2answers
26 views

Simple text Field Calculation In Arcpy [duplicate]

the function is very simple: arcpy.CalculateField_management (fc, "DFDD", "aaa", "PYTHON") and I want to calculate DHDD field with simple text "aaa", but I get error: name 'aaa' is not defined. ...
0
votes
1answer
16 views

Stacked with “expected a raster or layer name” error

I am using the following python script snippet but I get a TypeError: expected a raster or layer name on the commented line below. I could not find a solution about how to convert the A1 raster (that ...
1
vote
2answers
35 views

Check shape orientation

I have a shapefile with many minimum bounding box (envelope) polygons and I need to find out, if the boxes are rather landscape or portrait format. (See pic below, one of the selected boxes should be ...
3
votes
1answer
65 views

Using arcpy to find geometry within another feature

In Arcpy, I would like to start with a point and then using its geometry method to find out if it is inside my polygon feature (Urban Areas) deeper than the buffer distance. This is a follow up to ...
0
votes
1answer
21 views

How to Print the Labels of a Unique Value Classification Using ArcPy? 10.2

I have a layer where I have symbolized the features on unique values. I have also grouped several features together. EX) Layer: Land Use; Value Field: Type of Land Use; Unique Values of different park ...
1
vote
1answer
41 views

arcpy.da.Editor undoOperation(): does it actually work

Ok, so I have looked over the ESRI documentation thoroughly and I'm still baffled by the arcpy data access module and the function undo operation. So far I have tried: workspace = pathtofile ...
3
votes
2answers
67 views

Accumulated value from many rasters python/arcgis10

I need to calculate an accumulated value of temperature (as an additional raster) from many rasters. Is there any option to do this in ArcGIS 10 or any hints for a python script?
0
votes
0answers
20 views

ArcGIS Server throws an exception

I have a script in Python, that works well when I ran it in ArcMap. When I tried to execute it in ArcGIS Server as a service I got error this error: Failed to execute. Parameters are not valid.  ...
-3
votes
0answers
41 views

GeoProcessing Tool select by location (SWITCH SELECTION)

Right now i am working in Geo processing tool select by location i have use switch selection in arcMap python window (relationship passed "" & selected feature passed "" & search distance ...
0
votes
0answers
34 views

Cannot assign name to resultant terrain using ArcPy so cannot save result?

Question of python in ArcGIS: I can not assign a name to the resultant terrain, thus I can not save the result. I'm new to arcpy. By a piece of script using SetNull() in Raster Calculator, I want to ...
0
votes
1answer
33 views

Arcpy to append results of pivot table

Good Day All, So I have a script that does some processing but the main part are two things run a multiple ring buffer using arcpy.MultipleRingBuffer_analysis and four rings do some zonal ...
3
votes
2answers
104 views

Efficient ways to read table data from a large feature layer?

I have a feature layer that contains about 460,000 records and it currently takes about 20 minutes to read that table using the arcpy.da.TableToNumPyArray() tool. Is there a more efficient way to read ...
1
vote
1answer
31 views

NumPy Array to Feature Class: NameError from Inner Loop Variables

I have a NumPy Array to FC script that parses a JSON web-service. The outer loop writes to my FC correctly, however my inner loop variables come back as not defined when appending the items. The ...
1
vote
1answer
46 views

Output the Search Cursor as a string

I am trying to select Zones that intersect the dataframe (polygon). If there is only one return then I want to turn it into a sting. If there is multiple I want to turn it into a string with " ," ...
0
votes
0answers
17 views

Error 010240 when calculating mean of a list of rasters - Cell Statistics

I'm trying to calulate the mean value of a list of rasters but I am always getting the following error: RuntimeError: ERROR 010240: Could not save raster dataset to < value > with output format ...
0
votes
1answer
48 views

Why does Select Layer By Attribute give errors 000622 & 000628?

I try to select line segments from a layer "t_Pavement_Line which is open in TOC using the following line: arcpy.SelectLayerByAttribute_management("t_Pavement_Line", "NEW_SELECTION", ...
0
votes
3answers
81 views

Combo box in python add-in for Arc - keep selected value visible

This seems like a basic question that I cannot figure out. I have looked through other questions on gis.stackexchange and not found it, so forgive me if this is elsewhere. I have a python add-in for ...
1
vote
1answer
80 views

Python script to summarize layer properties

I recently found this layer properties script that summarizes layer properties in a single file or a directory and all subdirectories: ...
0
votes
1answer
42 views

address standardizer code in python for street featureclass

In my system I have featureclass Street and having fields. Featureclass : Street Input fields: NAME;STREET_PREFIX;STREET_NAME;STREET_TYPE;STREET_SUFFIX output fields: ...
1
vote
1answer
74 views

Map automation to iterate through attribute table using ArcPy?

I have a python code which iterates through all attribute fields and creates a map for each field automatically. However, in the code I have to specify each attribute manually which was fine so far. ...
0
votes
2answers
54 views

Python Crashes when Running ArcPy's ExportToPDF(), ExportToPNG(), ExportToJPEG()

I am attempting to loop through a folder of ~400 .mxd's and save each to a .pdf in another folder. All tested arcpy.mapping export functions (pdf, jpeg & png) kill python without a chance to ...
1
vote
3answers
56 views

Script won't delete feature classes from file database using ArcPy?

I wrote a script that creates a GDB using a designated parish/county name and then does a selection by location and extracts from another db to the newly created db. This all works fine but there are ...
0
votes
1answer
44 views

Debugging/logging ArcPy / Python code behind ArcMap function?

Considering I Can use the right click --> set datasource at an mxd file to change the datasource. The following pictures describes how this can be done in arcmap.. How can I see the arcpy / python ...
4
votes
2answers
108 views

How to Parse Unique Address Data

I'm trying to parse some funky address data into separate fields either using ArcMap's Field Calculator or a Python Script. Currently, my address data including street number, street name, and ...
2
votes
3answers
107 views

Best way to delete many fields from many feature classes using arcpy?

I'm currently formatting our GIS data for use in a mobile app. The purpose of altering the data is to reduce the output file size that's imported into the app. I need to delete many fields from many ...
3
votes
4answers
86 views

Python Script create spreadsheet with exception

In the following Python Script, I would like to create a spreadsheet (Excel would be fine) with the Exception results instead of just printing "There was an error--->..." to be able to keep track of ...