A site-package created by Esri to expose ArcGIS for Desktop (and ArcGIS Pro) geoprocessing, mapping, etc, to Python.

learn more… | top users | synonyms (8)

4
votes
1answer
58 views

ARCGIS Calculate Value Tool - Always returns same value

I want to check if an environmental shapefile was generated from a previous process. I utilized the Calculate Value tool in Modelbuilder but the problem is that no matter if this Wetlands layer ...
4
votes
1answer
53 views

Arcpy Copy_management does not copy all records

I need some help with a python script that is copying a shapefile to a new folder location. I am using ArcGIS 10.3. I have a shapefile of imagery tile outlines that contains 17425 polygons. I need to ...
1
vote
0answers
34 views

How to use arpy.mapping to change 'out jpeg' name to reflect page name

I am an experienced Arc user but new to python. I can not figure out where my syntax is wrong. I'm trying to use data driven pages to export to jpeg where the name of the file is the page name. It ...
1
vote
2answers
43 views

arcpy won't return correct data types of layers

I wrote this so that arcpy would give me the data types for each of the layers in a map document. But, "Feature Layer" is the only type of data that is returned (apart from "N/A"). Shapefiles are ...
2
votes
1answer
56 views

How to make arcpy to iterate through folders & sub-folders to access gdb's? [closed]

With reference to Check whether any feature classes in multiple gdb's has feature class representation, the code I've mentioned in the other thread is working great for single folder alone. We ...
1
vote
0answers
25 views

drop list from field to excute SQL request

i'm new to Python programming and now I try to create a python script that allows a selection attribute based on the name of a field in the attribute table of a layer and I would like to configure my ...
1
vote
0answers
23 views

Check whether any feature classes in multiple gdb's has feature class representation

I am trying to find whether any feature classes in multiple gdb's has Feature class representation. If a feature class has represenation, "RuleID" & "override" fields will be in the attribute ...
0
votes
1answer
44 views

arcpy.Erase_analysis function and output

I have attached my code (Python). I am trying to loop trough each FC in same file GDB and subtract a FC from remaining FCs not equal to input FC. Then want to create/generate FC from erased result ...
1
vote
0answers
47 views

Can't specify OID field in arcpy.MakeQueryLayer_management

I manage a library of query layers and have recently had the need to apply the same update to a bunch of them at once. Seems the only way to do that in python is to create new ones and apply ...
2
votes
1answer
91 views

Arcpy module to read csv files and create polyline shapefiles

I am creating a module in arcpy that will loop through a folder with csv files in it. I have both of them written, and they work fine on my computer. However when I send them to anyone else they won't ...
2
votes
0answers
17 views

How to create .sat files for .jpg tiles

I want to create map overlays for a TomTom GPS. Relief shading, ortophoto etc as map background while navigating in Map View mode. Instructions for creating custom overlay can be found here So far ...
3
votes
2answers
43 views

Arcpy Update Cursor with Character Length

I am attempting to create an update cursor to concatenate fields of a parcel ID based on the amount of characters in the MAPNO field. This is important because the spacing between MAPNO and LOT of ...
0
votes
0answers
41 views

Buffer FID assignment using arcpy

When buffer analysis is performed on a polygon what determines the order of assignment for FID? This came up with the following: arcpy.Buffer_analysis(inFC, outFC_50, "50 Meters") arcpy....
2
votes
0answers
73 views

intermittent failures with SelectByLocation in an ArcPy addin

ArcGIS 10.2, Windows 10 this is the line that fails: arcpy.SelectLayerByLocation_management(WRS_layer, "INTERSECT", gridLayer, "", "NEW_SELECTION") The WRS_layer is in a file gdb, the gridLayer ...
2
votes
2answers
47 views

Convert Date Field to String Field Arcpy

I have a Date field in an ArcGIS file geodatabase feature class called "DateTemp1." I created a new text field called "DateTemp2" and want to calculate that based on the DateTemp1 field, but I am ...
1
vote
1answer
41 views

Difficulty in sorting selected features

My script is terribly underdeveloped, I am trying to select cities within a country and then order these cities by their "POP_RANK" = population rank. I am not sure whether to use a searchcursor or ...
2
votes
2answers
77 views

Trouble with if/raise SyntaxError and ArcPy?

I am having trouble because when I enter a get parameter it takes me to the correct city name but it displays my SyntaxError also, but I want the SyntaxError to just be displayed when a city name is ...
1
vote
1answer
22 views

Search and Update Cursor Automation: Avoid <Null> Values and Recognize Data Values

I am attempting to Search Cursor through a joined table. (I do not have access to the original separated tables) If the value of "COMPANY" and "DATE_" are then they will be skipped and it is ...
3
votes
1answer
84 views

Get nearest polygons in both sides of a polyline with arcpy

I have polyline shapes representing roads and another shape layer with polygons that are representing buildings. I have to find some way with ArcPy to measure the distance from a point within the ...
1
vote
3answers
57 views

How to retrieve the processed file name, file path and save the result in a csv file using arcpy?

We have a list of feature-classes which are in multiple gdb's in multiple folders. This code is opening the csv and doing "GetCount_management" for the listed feature_classes alone and printing the ...
1
vote
1answer
34 views

count if a row value is within a dynamic range?

I am after doing a COUNTIFS in python. I need to check each row ± 250 with other rows and if this row is between that range then count 1, then next row, .. and do the same thing. and if there are any, ...
4
votes
2answers
105 views

Installing third party python libraries in ArcGIS location

I'm running ArcMap 10.2.2 for desktop and have Python 2.7 installed as part of the software package. I'm trying to get the pyexcel and xlutils libraries installed. I ran a script to find the path of ...
2
votes
2answers
72 views

Update Cursor: Unable to populate specific field

I am attempting to create a loop to recognize the entry/exit point of a pipe to/from a structure by associating it with a North, South, East, or West direction and then populate the corresponding ...
2
votes
1answer
21 views

Trouble Completing City Selecting tool

I am working on trying to create a tool which would allow me to type in any city name (in this cause European cities), and zoom into that city. My script will run but nothing is selected. I don't know ...
3
votes
2answers
132 views

Delete table rows in non-spatial database using arcpy

Working on a python script that does a bit of spatial analysis on a few layers, a spatial join of those layers, and then pulls data from a couple of other tables and holds them all in an in_memory ...
2
votes
1answer
29 views

Error in <module> arcpy.SelectLayerByLocation_management [duplicate]

I am writing a Python code and have trouble adding a layer to the program. I face this problem below: Traceback (most recent call last): File "G:\arcpy workspace\python learning codes\loc.py", line ...
1
vote
1answer
25 views

Getting NameError when using Cursors to read vertex coordinates in ArcPy? [closed]

I am new to python and having trouble Looping each feature in the new polygon shapefile, then use geometry cursors to read vertex coordinates of this lake polygon, identify the city that is the ...
3
votes
1answer
76 views

Confusion over arcpy.Describe() properties?

Can someone clarify the meaning of the 'fullPropsRetrieved'and 'metadataRetrieved' properties of a Describe object within ArcPy. In particular my confusion is regarding the definitions provided on ...
1
vote
1answer
40 views

How to make an arcpy tool to take multiple inputs csv/text lists, instead of a single input?

It's been only few days that i've been working in python environment. Based on this code, i've been trying to batch few process for our QAQC task's. At certain times, like when i use Describe.(...
1
vote
1answer
67 views

Python Script GetParameterAsText?

I am writing a python script to be added to a toolbox and I do not know how to call an existing tool to be a parameter. import geocoder ##geocoding library import csv import arcpy ##...
1
vote
3answers
181 views

Changing single character in attribute table with ArcPy?

I was trying to speed up my data processing, and I was wondering, which would be the python code, that could browse through my shapefiles, and find special single characters (which I define) in ...
0
votes
0answers
31 views

Extracting projection details for TAB files from multiple folders using arcpy's describe spatial reference?

I am trying to extract projection details of vector files (it might be a tab or shp file) in multiple subfolders using arcpy's describe.SpatialReference. If i run this code, i am getting this error. I'...
2
votes
0answers
28 views

Python Script to apply the Northing and Easting of a photo center .shp file to a tiff. [duplicate]

I have a group of tiffs I want to georeference. I have the photo centers for each of the tiffs but they are not linked. After looking at the comments I believe there would be a way to take the ...
1
vote
1answer
38 views

Updating Field to Calculated Variable using Arcpy

I'm trying to use the updateCursor to insert a calculated value in the correct field. However, I keep on receiving an execution error. I think it is an easy fix, but I am new to arcpy and cannot ...
2
votes
1answer
83 views

Changing Query Layer's SQL Expression with Python

I use query layers in ArcMap 10.4. The maps need to be done/repeated periodically. The easiest way is to copy the map, change the source's SQL expression (e.g. from select * from TABLE where Period = '...
2
votes
1answer
50 views

Append tool Error “WARNING 000594”

I am trying to migrate a dataset from one fileGDB to another using the Append tool. When running a few features get copied over however the rest get the following error: “WARNING 000594”: Input ...
1
vote
1answer
85 views

(Arcpy) read values from a txt file and convert the data into a shapefile

I´m a beginner at python programming and wanted to start with a litte and hopefully simple project. I tried to read float values out of a textfile and write them into a shapefile. The program is ...
2
votes
2answers
67 views

ArcGIS Server - Can python GP services returns json data to client through REST?

Can python GP services returns json data to client through REST? Imagine I have a python GP service that creates buffers around points and then merge the polygons together. I would like to send the ...
3
votes
1answer
66 views

Calculate visibility with polygonal visual barriers

I have the raster file for my digitial elevation model as well as a polygon shapefile with polygons representing different kinds of environments (forest, field, meadow, etc), and wouldlike to ...
1
vote
1answer
38 views

Iterating a model that contains values too low [closed]

Beginner Python programmer here, I have exported my Model Builder model from ArcGIS to Python. What I am trying to do is provide some kind of clause saying "if the data selected has less than 2 ...
1
vote
2answers
52 views

Creating a subselection with arcpy

I want to do the following: from a point layer's table, 1) grab all GEBID (an attribute) and create a list(1) with unique GEBIDs 2) iterate through the list(1) in a loop:   2a) stuff all features ...
0
votes
1answer
37 views

Create feature datasets from group layer name

Is it possible to create feature dataset, based on the name from group layers. I have two separate codes, one for finding out the names of group layers, and other to create feature datasets. >>...
1
vote
1answer
50 views

How do I get arcpy.Select_analysis to skip conditions that don't exist

I have data from 2007 to 2015 of various animals that I'm trying to break up by year and name. I wrote a little for loop that goes through all the items in my attribute table (gps_points). The ...
0
votes
1answer
30 views

Background color changes when projecting a raster with ArcGIS 10.4

I'm using the Project Raster tool via arcpy: arcpy.ProjectRaster_management( in_raster = clipped_raster, out_raster = projected_clipped_raster, out_coor_system = ...
0
votes
1answer
29 views

os module can't find time files were created, because “system can't find file specified”

I have ~200 layers in a Map Document, and I am trying to find the dates that these layers were created on (so I can export to database later). Some of these layers are housed in groups and sub-groups ...
2
votes
2answers
27 views

Reference Items in Generated List for Multiple Record Selection and Iterate

I'm new to Python and am having trouble with a list of all things. The data I am currently working with consists of multiple road segments (contained in 'STREETNAME' field) each of which has a ...
1
vote
0answers
41 views

Versioning in ArcGis? [closed]

I create 2 replica by tool CreateReplica_management. This tool return 2 mdb: A.mdb with feature class FC1, FC2. B.mdb with feature class FC1, FC2. First user edit FC1 from A.mdb Second user edit FC2 ...
3
votes
0answers
33 views

Automatic point plotting in ArcGIS from thresholded image [closed]

I would like to know whether it is possible to plot points automatically on a map in ArcGIS by using a raster file as a reference. The image below would represent an example of line that comes from ...
0
votes
2answers
38 views

Get List of manualy selected features on MXD and run script on selected features : [closed]

Using arcgis 10.3, I trying to write code that when i do selection on layer manualy on MXD (not in the script) and run the script, the script need to run just on the selected features. I have tried - ...
0
votes
0answers
42 views

How to georeference *.tiff to a given feature geometry automatically?

I´ve got the task to georeference an tiff image to the referencing polygon footprint (Polygon). I have found a lot of ways to do get the footprint from a raster but I could not find a way to use ...