Python toolboxes are geoprocessing toolboxes that are created entirely using Python in ArcGIS 10.1 (and later) for Desktop

learn more… | top users | synonyms

1
vote
0answers
34 views

Updating Field Mappings Parameter on table selection in Python Toolbox?

I am building a python toolbox with ArcPy and would like to associate an input feature class parameter with a field mapping, so that once user selects the input feature class the field map populates ...
6
votes
0answers
178 views
+50

Python toolbox works in ArcToolbox and in Python console, but not in ArcCatalog

I have a set of Python tools in a Python toolbox (.pyt). They are broken into multiple files and modules and have been functioning correctly, but now I'm seeing inconsistent behavior on multiple ...
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 ...
1
vote
1answer
43 views

How can I programatically set the “Description” for a ArcPy Geoprocessing Service?

When I create a Python Toolbox (pyt), I set the name and description of the toolbox. When I create the parameters, I can set their name, type, default value, in/out, etc. Basically, everything that ...
1
vote
1answer
38 views

Field calculater in Python console from QGIS

I have some doubts in syntax of processing.runalg(qgis:fieldcalculator) in python console of QGIS. I want to create a new field in a shapefile and calculate this formula: [D_PATRICIA]*1000. ...
1
vote
1answer
37 views

Returning feature class from Python toolbox

I am trying to return a feature class (my sample data is a polygon fc) from a Python toolbox and cannot find any information about what I have to set to get it to work. This runs successfully and ...
3
votes
2answers
110 views

ArcGIS tool for graph analysis

I have a road network shape file. After creating Network dataset I get a graph with vertices and edges. I need to create a tool for ArcGIS (through a Python code) which enables to calculate depth of ...
0
votes
0answers
33 views

Problems with using python script in ArcGIS for Server 10.1

I have a geo-processing model that works perfectly in ArcGIS desktop (10.1) and successfully publishes as a GP Task to ArcGIS Server (10.1). Once I try to execute the GP task (either through a widget ...
1
vote
1answer
56 views

How do you use Windows folders as acrpy Parameters

I am having problems trying to perform simple folder management operations in an ArcGIS python toolbox. First here's some code snippets (I have left out all of the stuff that does not pertain to this ...
0
votes
0answers
53 views

Python toolboxes missing (Can't use ArcGIS 10.2.2 toolboxes)

I was trying to use Hot Spot Analysis Toolbox on ArcGIS 10.2.2 but this error message appears: updateParameters Syntax Error Runtime error Traceback (most recent call last): File c:\program ...
0
votes
0answers
53 views

Creating a custom toolbox and python script to analyze fire data

My goal is to create both an ArcGIS toolbox and an independent python script to do the analysis of fire occurence in the Southwest (by season) through ArcMap as well as independently with python. I ...
1
vote
1answer
51 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
vote
1answer
39 views

pop() method returns error with feature class list in ArcGIS python toolbox

I am trying to do something very simple, but I'm pulling my hair out with this one. In an ArcGIS python toolbox, for one of my tools I ask the user for a list of feature layers, using the following ...
2
votes
1answer
87 views

How can I use updateParameters to handle both points AND polyline feature layers?

I'm using ArcMap 10.2.1 and Python 2.7.5. I would like my updateParameters to enable and disable fields based on if a feature is a point or a polygon. If the point is selected then I need the ...
2
votes
0answers
102 views

ArcGIS python toolbox: GPFeatureLayer parameter “loses” symbology type

I'm pretty new at ArcGIS python toolboxes. Here is one problem I've been fighting with for a while. I want to create an output layer (GPFeatureLayer) with a specific symbology (GRADUATED_COLORS) and ...
1
vote
1answer
66 views

Set GPLinearUnit type parameter default based on input spatial reference (Buffer Example)

Within a .pyt python toolbox I'd like to have a parameter of data type GPLinearUnit get a default value based on an input Feature Class (FC). The standard Buffer (Analysis) tool works as a great ...
0
votes
1answer
43 views

GPRecordSet in python toolBox

I would like to use a GPRecordSet in my python toolBox as an output parameter. This geoprocessing will be share on my ArcgGIS server and in my ArcGIS portal. I haven't see any documentation on how to ...
1
vote
1answer
112 views

Running Python toolbox tool both standalone from other tools within same Python toolbox?

I have created a python toolbox for work that has two tools inside. These tools use the toolbox template and so have a init, getParameterInfo, etc. I want to be able to run one tool both stand alone ...
1
vote
0answers
66 views

How can I extract the measurelength, highmeasure and lowmeasure of routes in ArcGIS

I'm trying to create road Routes in ArcGIS, which traditionally have been created using workstation. I've managed to write a Python script to do this, however, unlike ArcInfo, the attributes ...
1
vote
2answers
93 views

Calculate field management not working within customized Python tool in ArcGIS

I am trying to make a custom made Python Script tool which I would like to use in Model builder. I am using the arcpy.Calulate_field_management function (simple reclass function as an example), but it ...
3
votes
0answers
167 views

Arcgis arcpy toolbox multiply files: error - module object has no attribute

I have a big .pyt script (python toolbox) and now i trying split it to many files (1 file - 1 tool). In single .pyt file everything works perfectly, but when file is splited i get this message: ...
0
votes
1answer
126 views

Python Toolbox Parameter List Update/Refresh?

I am using a python toolbox in ArcGIS 10.2.2 and want a drop down list of all the versions for the person reconciling to choose from. (And I do not want to include dbo.DEFAULT and DS.Draft). But this ...
2
votes
1answer
155 views

ArcGIS Python Toolbox Parameter Filter.List ValueList Delete/Remove for Reconciling Versions

Does anyone know if and how you can remove a value from a parameter filter list? In my case, I am using a python toolbox in ArcGIS 10.2.2 and want a drop down list of all the versions for the person ...
2
votes
2answers
187 views

Permanently add a python toolbox to ArcToolbox

I've written a python toolbox for my company containing several scripts to speed up various repetitive tasks. Each time we want to use it we have to open ArcToolbox, right click and select "Add ...
1
vote
0answers
32 views

Is it possible to call a complicated query as a stored procedure within a geoprocessing service?

I need to implement a searching geoprocessing service. A part of the query should be very complicated and use oracle text. My service should support spatial search too. 1) I am thinking of ...
1
vote
0answers
48 views

ODCostMatrix in a Python Toolbox, field mappings questions

I am trying to create a Python Toolbox in ArcGIS to accomplish Network Analyst tasks. Globally the toolbox has to create and solve an ODCostMatrix Layer. The users has to enter Origins and ...
1
vote
0answers
56 views

Using choice of one parameter to populate column of multi-value control ready to have values for second column chosen?

This relates to my earlier question Can one parameter choice on Python toolbox tool set Display Names of other parameters?, but attempts to describe the requirement, rather than my attempted solution, ...
4
votes
2answers
246 views

Can one parameter choice on Python toolbox tool set Display Names of other parameters?

I would like to be able to create a Python toolbox tool (or a Python script tool) where a choice made from the first parameter (Category in the images below) changes the Display Name of other ...
2
votes
1answer
192 views

Tutorial on creating python toolboxes?

I've done the ESRI training: Creating Python Toolboxes Using ArcGIS 10.1 but is there anything more in depth? Since VBA is no longer supported in ArcMap 10 and up I'm trying to convert a cross section ...
4
votes
0answers
107 views

Configuration problem anaconda python in ArcGIS

I used Eclipse with PyDev to create a script in Python (windows 7 x64). My code runs perfect when I start the run in Eclipse, but when I add it as a Tool in ArcGIS 10.1, I have the following problems: ...
0
votes
1answer
64 views

Using valueAsText, giving me unicode data instead of a list

I am learning Python to create toolbox right now. When I'm trying to get the parameter, using valueAsText, the date returned is unicode instead of a list that I was expecting. This is the code that I ...
5
votes
1answer
467 views

Set default values for value table in Python Toolbox tool

I created a Python Toolbox tool to reorder fields and create a new feature class with the reordered fields. The tool works nicely and I am able to use a value table to let the user arrange the fields ...
0
votes
2answers
149 views

Select value from list in Python toolbox

within a Python toolbox in ArcGIS 10.2 I fill a parameter with a list. parameters[0].filter.list = myList It is essentialy a list of strings and will give the user a range of predefined years. Later I ...
-2
votes
1answer
122 views

Cause of KeyError in Python Toolbox of ArcPy?

This question arises from Performing Point Distance analysis using Basic level license of ArcGIS for Desktop?. I basically copied and pasted PolyGeo's answer and formatted it into a python toolbox ...
2
votes
1answer
185 views

How I can do event with two clicks using python add-in wizard?

How I can do event with two clicks using python add-in wizard, I have found a way to do event with one click by adding a New Tool in the wizard, but I need "first click To copy the attributes from ...
0
votes
1answer
75 views

How to group tools within a Python toolbox in ArcMap 10.2

I have created a simple Python toolbox at work for use in ArcMap 10.2. It is used by multiple members of staff so I'm hoping to make it as simple to use as possible. It currently only contains two ...
3
votes
2answers
397 views

How do updateParameters and updateMessages Interact in a Python Toolbox?

I have been developing a Python toolbox which consists of 6 parameters. I have received immense amounts of help on this through StackExchange through the following posts: How to Determine if a Layer ...
7
votes
2answers
211 views

How to Determine if Layer is a Point

I have been working on a Python toolbox which contains 6 parameters. I am a little lost on all of the different data types available in ArcMap (it seems like there's hundreds of them!). However, one ...
2
votes
3answers
217 views

How to Change Parameter Type from Optional to Required

I am creating a Python toolbox with 5 parameters. One of the parameters is a Boolean/checkbox, which checks if the user wants to edit the labels of a shapefile. What I would hope to do is if the user ...
1
vote
2answers
54 views

Optional Parameter Not Being Optional in a Toolbox

I have been creating a toolbox that contains 4 parameters. Two of my parameters involve editing the labels of a shapefile. I want to have these two parameters as optional: if the user does not want to ...
6
votes
2answers
323 views

Can ArcGIS Pro use Python toolboxes written for ArcMap?

Can the new ArcGIS Pro use existing ArcToolbox scripts? Or to put it another way, will I have to rewrite my existing ArcMap toolbox & python scripts if I want them to run in ArcGIS Pro?
6
votes
1answer
71 views

Ordering tool display within a Python Toolbox

I have created a python toolbox containing a number of classes which define the various tools within. As these classes are part of a workflow in which the tools are to be executed sequentially using ...
1
vote
1answer
140 views

Esri Python Toolbox(pyt) corruption in ArcToolbox.dat

Symptoms: Open ArcCatalog and all tools within Python Toolbox(pyt) have a red-x error next to them claiming that "Arcpy module has no attribute Parameter" Close ArcCatalog Delete ArcToolbox.dat file ...
2
votes
2answers
183 views

ArcGIS - Getting Python toolbox to function properly

as the header says, I do have a problem in getting my toolbox to function the way I want it to. In the following my parameter definition is shown, where from I would expect to get only feature classes ...
2
votes
1answer
87 views

Parameter Not Being Included in Tool

I have been attempting to make a Tool within a Toolbox with four different parameters. My code consists of the following: def getParameterInfo(self): """Define parameter definitions""" # ...
2
votes
2answers
88 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. ...
1
vote
1answer
376 views

geoprocessing service via python toolbox script, local versus server paths

So I feel like I'm missing a very basic concept when it comes to publishing python toolbox scripts to a geoprocessing server. I've scoured the ArcGIS online help (not saying I've read everything, and ...
1
vote
1answer
162 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
0answers
30 views

getParameterInfo datatype for creating new feature class

I'm having trouble finding a suitable datatype that allows the user to browse to a .gdb and create a name for a new feature class. DEFeatureClass wants an existing FC to write to. Using ...
1
vote
1answer
144 views

How to print log from FME when run from python script?

I created a Spatial ETL ToolBox in ArcCatalog. When I run the tool from ArcCatalog I see log massages. But when I run this tool from a python script, the logs do not print to the python console. ...