A site-package created by Esri to expose GeoProcessing from ArcGIS to Python.

learn more… | top users | synonyms (7)

2
votes
2answers
50 views

Creating a list using an attribute query with arcpy.da.SearchCursor

I have a shapefile of a river network containing the following fields: toJunction, fromJunction, Int_DAM (which indicates free-flowing status) and Strahler. I'm trying to create a list of the rows ...
0
votes
0answers
34 views

ArcGIS 10.2 Custom Tool Sort Drop-Down-List by another field of table

I'm making a Custom Tool in which the user could select one input-parameter from a field of a table as a Drop-Down-List. The issue is, that I don't want to sort the Drop-Down-List in alphabetical ...
4
votes
3answers
358 views

Why [0] is needed in row[0] when using ArcPy (Data Access) cursors?

when running the following 2 sample codes, "[0]" is needed to be added after "row" in order to make code run well. I was confused. can anyone help explain? I know that it might be too easy for most of ...
0
votes
0answers
8 views

Display 3D collada files and shapefiles [duplicate]

How do I display 3D Collada (or Multipatch) building model along with some 3D buffer shapefiles using python? I was using arcpy for buffering, but arcpy does not have the feature to add shapefiles ...
0
votes
2answers
47 views

Importing/Plotting Lat/Long points from single column of *.csv using Python?

I have data in a .csv that looks something like this: Entry A Xa0,Ya0 Xa1,Ya1 Xa2,Ya2 Entry B Xb0,Yb0 Xb1,Yb1 Xb2,Yb2 Entry C Xc0,Yc0 Xc1,Yc1 Xc2,Yc2 The ultimate goal is to plot ...
1
vote
0answers
29 views

creating a new layer/selection based on the conditions in Python script? [closed]

Is there any easy way how to write a python script, which would create a new layer based on location from a border line and "if" condition? I have two layers A and B, both are made of several ...
1
vote
1answer
35 views

Point coordinate shift after python toolbox processing

I am working on custom clustering in ArcMap. For it I have created a python toolbox, where I do the processing. However, as a result I get slightly shifted points (6-20 meters), while they shall stay ...
3
votes
1answer
67 views

ArcGIS model and python script integration

I'd like to make a model with a last step, a python script, that will send an email, containing messages and status of the model. The email sending part is okay, thanks to the community. The hard ...
0
votes
1answer
17 views

ArcGIS Group points that sum to a certain value based on the the closest distanceto main feature

I am looking for a tool, or a set of tools/procedures (scripts or models) that will calculate the distance from one Main point to a cluster of points around it, then selects or joins, or somehow ...
0
votes
0answers
27 views

how to export selected data to json format

I have a layer called parsel. I want to export all history of this layer. I created parselall_view with history tables (A,D) , I want make a geoproccessing service that service all data of ...
2
votes
1answer
76 views

Making a tool from script, arcpy.Project_management () comes with an error

I have a script (just a fragment here, up until the line after which the error comes up): import arcpy from arcpy import env arcpy.env.workspace = arcpy.GetParameterAsText(0) ...
0
votes
2answers
34 views

running scripts of codeblocks in arcpy with syntax error

I am having a trouble in running the following scripts: import arcpy arcpy.env.workspace = r'C:\MyData\my_geodatabase.gdb' max = 123 min = 0 mean_s = 12.3 expression1 = "test(!mydensity!)" codeblock1 ...
0
votes
0answers
22 views

Ansible/TeamCity/arcpy import issues

we are trying to implement remote instantiation of a python application that uses arcpy. The scripts work perfectly fine when running on the virtual machine when logged in as a user. However when ...
1
vote
1answer
48 views

Arcpy get values in the 2nd field of every table in a geodatabase

I have a geodatabase in Oracle with around 50 tables. I want to get the values in the 2nd field of every table in my geodatabase. I will be using the values in the 2nd field as an input for a ...
6
votes
2answers
128 views

Spatial Join Yielding NULL values in ArcPy?

I'm writing an automated script to do some data processing of address points. One stage of the process is to retrieve 19 fields of information from various polygon layers that the Address Points are ...
0
votes
0answers
28 views

Feature Layer parameter showing only Polygon Shapefiles

I have created a Python Tool in ArcGIS where most of the paramaters musts be ONLY Polygon Shapefiles. You can also look on my previous question: Filter the Feature Layer parameter in Python Script ...
1
vote
1answer
92 views

Zoom/Pan function in python addin tool

I have created one python addin tool which creates some points along a line, it works good. my problem is when my tool gets activated i am not able able to zoom/pan the map. map view just get stuck ...
2
votes
1answer
40 views

comparing rasters, cells that have changed value

I am attempting to compare two rasters representing a species distribution model for now and the future. The rasters have the exact same extent and cell sizes. here is when is gets tricky, they are ...
2
votes
1answer
37 views

Change Date to Future Date in Map Title Using Python or Dynamic Text [duplicate]

I'm trying to create a dynamic map title in ArcMap that updates based on current day + 2 days. For example, if I run the code on the 20th of a given month, the title should update to show the 22nd. ...
1
vote
0answers
32 views

Why are my modifications to UniqueValuesSymbology classLabels not following through to PDF export? [closed]

I have a vector layer that I add to a data frame. I modify the unique values symbology class labels. I then export the map document as a PDF and the labels in the PDF do not reflect the modifications. ...
1
vote
2answers
51 views

Error 999999 exporting table view?

ArcGIS 10.1. When I try to export a table view with CopyRows_management, I get an invalid sql error. However, the sql statement by all accounts work fine. When I perform a GetCount_management, the ...
2
votes
2answers
67 views

Wrap text element labels

I am writing a python script for batch map production and for every map the script replaces a text label called "Company". sometimes the name is way to long and it extends onto the map and off the ...
1
vote
1answer
30 views

Use previous results as rectangle in Clip_management

I would like to use arcpy.Clip_management to clip a raster to a previously generated feature class (using ClippingGeometry), but still have to enter values for a rectangle, under the form "Xmin Xmax ...
3
votes
1answer
100 views

Compare and update values from different source using arcpy

Shape file: "table1.shp" Field name: "Name" Field name: "Result" Flat file: "referenceTable" Field name: "STREET" Field name: "AKA" I need to compare the value "Name" in "table1.shp" to the ...
5
votes
1answer
102 views

Field Calculator text field to new shapefile

I have point features being selected by a polygon feature and copied to their own shapefile. I also have certain values of the polygon feature being applied to the newly created point file. The ...
1
vote
0answers
38 views

Arcpy create feature class representation

I have written a script which allows me to select multiple feature classes and apply both a representation (based on a template layer) and set a transparency value before adding to the map. ...
0
votes
1answer
73 views

Using Python Script to get equal name as given and compare to multiple shp file in folder and copy as output for tool?

The following images will show my model. I used a piece of Python script and trying to get the output from it as a layer and use it for rest of the tool. However, I am getting error as displayed in ...
1
vote
0answers
19 views

Cursor update row operator [closed]

This is a find and replace script I have been working on. I feel I am very close, as the script does everything but actually change the values, leading me to believe there is an operator issue. I have ...
2
votes
1answer
39 views

MXD defined symbology not retained

I'm trying to create some layers from feature classes located in the geodatabase. The MXD is created, symbology on feature classes defined within ArcMap, but for some reason my symbology is not ...
3
votes
1answer
35 views

Writing Python Script to get equal name as given and compare to multiple shp file in folder and copy selected shp file to new folder?

Need to go through multi shp file in a folder and copy a single feature which has the same name as entry to the new folder with staying same name and format. I create a piece of python code that can ...
1
vote
0answers
20 views

ListBookmarks does not output any features [closed]

I'm trying to use ListBookmarks in Python to output my bookmarks to features. I directly copied the code in the sample provided. It "succeeds" and creates the feature class I wanted, but it is empty ...
1
vote
1answer
57 views

Arcpy Creating Multi-page Table/PDF with Reportlab/PyPDF2

I am writing a scrip to batch automate hundreds of map PDF's. Along with the PDF's I generate a unique Table/reportlist for each map from the 'receptors' that fall within each boundary of the map. The ...
2
votes
1answer
26 views

Conversion of Sirgas2000 projection system to wgs84

I am having a bunch of .csv files containing "x" and "y" of some locations (to be specific, Brazil and the coordinate system is SIRGAS 2000). I want to convert them into wgs84 i.e, lat/long using ...
2
votes
2answers
82 views

AttributeError: 'NoneType' object has no attribute 'split' from arcmap only

I'm running a simple python script from arcmap that sends an html post and processes the response. This script runs just fine from pythonwin but for some reason I receive the following error when ...
2
votes
1answer
33 views

How to select certain fields from a feature class to create a new feature class

I am stuck on how to create multiple features classes from one feature class using a select few fields. I have the following attribute table for a shapefile. I would like to select the 'USAF', ...
2
votes
1answer
51 views

Polygon scaling using arcpy

Is it possible to scale each polygon by a numeric value in an attribute table field using arcpy. I have updated the code from some previous excellent work done by Evil Genius import arcpy import ...
2
votes
2answers
113 views

ArcPy Calculate Null Values to Zero in Multiple Fields

I have a table that has Null values and I would like to insert a portion in my script to calculate these Null values to 0 in only a few of my columns in my table. Here is my script so far: with ...
2
votes
2answers
30 views

How can I alter the value field in a raster?

I'm using ArcGIS. I have a raster with angles in the value field. But the value field is type long integer. I would like to change it to float. Is that possible? Some more details: I've started with a ...
3
votes
1answer
35 views

Calculating summary statistics and access resulting value in table using ArcPy?

With arcpy, I want to calculate the mean value of a specific field in a shapefile and print the resulting value for the user. I use the Summary Statistics tool and it works, but the resulting value ...
0
votes
1answer
23 views

Clip tool gives ERROR 000732?

I am trying to execute clip tool in python on arcGIS 10. But it gives error: ERROR 000732: Output Extent: Dataset D:/Work/Map/SampleGdb/Sample_02.gdb/Sample_02.gdb/Subcatchments does not ...
0
votes
1answer
53 views

Creating polyline using mouse clicks with Python Addin tool?

Can somebody tell me how to create a line geometry by mouse click with python addin? I am using below code in python addin tool. class ToolClass8(object): """Implementation for Testmsg_addin.tool ...
0
votes
1answer
36 views

SelectByAttribute is not working (ArcGIS, Arcpy. Python script) -

My script is below. I use to file from filegeodatabase to select all of rows (in a loop, one by one) to create a simple map and export it to jpeg. For some reason, once I updated my script to run ...
0
votes
1answer
37 views

Total Count in Attribute Table

I am trying to add all of the counts in an attribute table, to get the total number of counts (I am trying to figure out the percent aspect for a polygon). My code works fine, I am not getting any ...
3
votes
1answer
38 views

Getting full path for feature classes in dataset using ArcPy?

I have a python script that I am writing to create a copy of a database and then clean it up (basically remove any empty items). Everything is working with the exception of feature classes that are ...
2
votes
3answers
54 views

Search directory of shp files for an empty attribute value

I'm trying to search through a directory of shp files for any shp file with a specific field that is empty. Here is my code as of right now. import arcpy from arcpy import env env.workspace = ...
0
votes
1answer
42 views

arcpy custom script tool to find and replace floats and ints?

I created a custom script tool that can find and replace text. See the image link for what my tool interface looks like too, and I'll point out the find and replace fields are both set to string in ...
5
votes
1answer
62 views

Creating ArcPy scripting tool with dropdown box for sql expression choice

I am creating an ArcPy scripting tool to allow users to select a feature from a feature layer and then zoom to that selection. I have successfully created this tool and now am working on creating the ...
1
vote
0answers
97 views

Python with ArcGIS: import scikit-learn fails (bad numpy.dtype)

I am trying to install scikit-learn 0.17.1 (current) into my Python 2.7.3 that accompanies my ArcGIS 10.2. The installation through easy_install goes through smoothly, but I get the following error on ...
3
votes
2answers
30 views

ArcGIS 10.2 Model Builder If no selection is made, then do not append to empty feature class

I'm creating a model in model builder that is very easy to construct and understand. However, I ran into a slight problem. The logic of the model is that it will take user selected features from a ...
0
votes
0answers
16 views

Create Polyline line by Mouseclick using python addin [duplicate]

I am trying to create polyline by using python Addin tool. but could not understand properly how it works. the Python Addin Tool is not much documented in Esri Website. so i am not able to understand ...