A python extension to a software program that performs a custom task.

learn more… | top users | synonyms

1
vote
2answers
60 views

Python Add-in using arcpy.mapping.ListLayers() does not update when run multiple times

I am developing a Python Add-in for ArcMap 10.4 that, upon a click on a map, opens a wxPython GUI that contains a combo box listing the layers in the map document. Here's a current snippit from my ...
1
vote
1answer
37 views

Alternative to self.Destroy() for wxPython in Arcmap?

I have created a Python Add-in for ArcMap 10.4 that involves a wxPython UI to display upon a click on a map. The UI is populated with default values as well as a combobox displaying the layers on the ...
0
votes
0answers
27 views

000800 error for versions only when working in a geodatabase that uses an Operating System Authentication for its connections

I wrote a toolbar that takes some input and uses it to modify an SDE geodatabase. It usually works well in a geo database that uses Database Authentication for its connections , but recently I ran ...
0
votes
1answer
20 views

Dynamically editing items in combobox of Python AddIn?

I'm trying to dynamically edit the list of items in a combobox I made using python add in for a toolbar I'm working on. The list is calculated by another button. Here is the relevant code: class ...
5
votes
1answer
407 views

Building progress dialog with pythonaddins in ArcMap? [closed]

As a component of my add-in, I compute a bunch of summary statistics when the user clicks a button. This can take a while to process and it can appear as though the program has stopped responding. I ...
0
votes
4answers
62 views

Setting selection method in ArcPy?

I haven't found a way of setting the selection method (Create new, Add to current, Remove from current, Select from current selection) in arcpy. Is it possible to do this and - if yes - how? I am ...
4
votes
1answer
118 views

Creating Python Addin Button?

I want to create a Python AddIn button to execute a specific script. I know how to use the python addIn wizard and add the toolbar I created in my ArcMap. The trouble I am having is writing the script ...
5
votes
1answer
501 views

Select and copy attributes features in ArcMap using Python add-in tool?

I'm trying to add a tool to an add-in toolbar to select features from an existing feature class and copy attributes to another feature class,from point to point. TopoHeight_Field_Name='Comment' def ...
3
votes
1answer
300 views

Opening PDF generated by Python AddIn using Report (*.rlf) file automatcally?

As a test I have: Authored a test.mxd with one layer called Localities in a single data frame called Layers Authored a test.rlf using View | Reports > Create Report of ArcGIS 10.2.2 for Desktop ...
0
votes
1answer
146 views

How so I solve FDO error: 0? How do I get code that worked in a file geodatabase to work in an SDE version?

I used python add in to make a tool bar in Arcmap that edits features on a map. It works on a file geodatabase, but not on an ArcSDE version one. I've been getting an FDO error: 0. The potential ...
3
votes
1answer
33 views

AddRaster using pyqgis

I am able to attach a raster by using python console using the command shown below. qgis.utils.iface.addRasterLayer('D:/Work/dt0017810q.tif') But, when the same image/raster path is read from a ...
0
votes
1answer
51 views

python addin manager validation of code

I have a toolbar (in ArcGIS) set up with two buttons using python addin manager, can someone help me make sure this works, when I run these buttons nothing happens. import arcpy import pythonaddins ...
0
votes
0answers
18 views

combobox show two layers: selected layer + 1 field of another layer

I am new to Python, I have problem with combobox. When I select one layer of list, I want to show selected layer and near analysis from another table. Or When I select one layer of list, I want to ...
6
votes
2answers
540 views

Can ArcPy fill forms in Add-in interface?

I'm trying to build an ArcPy tool, which will ask the user to input some information (ID, Name, Address, Zip, etc.) first. My add-in interface is shown below, and hope to implement that once the user ...
0
votes
1answer
125 views

ArcGIS Python Add-in using non-GUI window

Does anyone know how to create ArcGIS Python Add-in, that will allow after clicking on a feature, open a new window with a few pictures connected with the feature and then let the user change these ...
1
vote
2answers
69 views

Why can't I open this workspace?

I used python add in to make a tool bar in Arcmap that edits features on a map. It works on a file geodatabase, but not on an ArcSDE version one. I've been getting an FDO error: 0. The solutions that ...
1
vote
1answer
45 views

Finding correct service for arcpy.createArcSDEconnectionFile_management in ArcPy?

I'm working on a toolbar for modifying an SDE database in acrmaps. My code works in a file geodatabase so I'm trying to use this function to make it work in an ArcSDE. I've gotten every other variable ...
4
votes
1answer
51 views

Clear combo box in ArcMap Python Add-in

Recently created my first Python Add-In for ArcMap. It has been deployed for about a month now and the users like it. There is one thing I want to fix. The Add-in has two combo boxes: In #1 the ...
-4
votes
1answer
40 views

Getting nearest feature point from other features in point layer? [closed]

How i can do this Get the nearest feature point from the other features point in a point layer Point feature class and make it in script tool
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 ...
3
votes
0answers
28 views

Get results for each topology errors for Polyline or Points? [closed]

When you set up a topology to build topology rules for each polyline, or points, is there a way to get the results or summary for each Line Errors? For example, when you set "Must Not Overlap", "...
2
votes
1answer
61 views

Python Addin - Disable Toolbar in Layout View

I'm trying to disable a toolbar with nested menus and buttons when an mxd is in layout view, but it's not working. I also get no output in the ArcGIS python window when I switch to layout view. ...
2
votes
1answer
73 views

Script slow because of conditional statements

I have created a Python addin for ArcMap. It has two comboboxes. Combobox1: Search for facility by name. If there is one facility with that name the mxd zooms to the selected extent. Combobox2: ...
2
votes
1answer
78 views

Arcgis 10.2.2 Python Addin - Add Layer to Layout View?

I've developed a python addin toolbar that adds a desired layer file (chosen from a button nested in a menu in the toolbar) to the table of contents in a project. The functionality only works, ...
1
vote
0answers
55 views

Creating button on Python AddIn toolbar to run python script when clicked? [closed]

I need to create a button on toolbar of arcgis 10.2 who run a python 2.7 script created before when I click. Then I need to know if it's possible in this button that script write results to an excel ...
-1
votes
1answer
65 views

Insert Cursor not creating polygon

I used this code to create a polygon in my map, but the polygon isn't showing up anywhere. Does anyone know why? Here is my code: fc = "U:\BuildingFootprints.gdb\BuildingFootprintsCopy" cursor = ...
0
votes
1answer
55 views

Arcpy 10.3 add ins [closed]

I am working with arcpy 10.3 and i want to build a add-in. Unfortunately it's not working when i add a button like: import arcpy import pythonaddins class ButtonClass1(object): """Implementation ...
1
vote
2answers
80 views

Why my button in ArcGIS add-in extension shows as “Missing”?

I do not understand why my add-in toolbar and button shows up as "Missing" when I open ArcMap. I am not sure whether this is an issue with ArcMap 10.3 or whether I did anything wrong. Have anyone ever ...
1
vote
0answers
313 views

Is it possible to open *.dmp file and find out what cause ArcMap to crash?

Is it possible to find out what cause ArcMap to crash from *.dmp file? This files are located here: C:\Users\user\AppData\Local\ESRI\ErrorReports I have made some Python add-in to ArcMap wich ...
0
votes
1answer
90 views

ArcPy Python Addin Combobox How to leave a if-loop, when selection is found

ArcPy Combobox How to leave a if-loop, when selection is found I developed a Combox which: combines values from different featurelayers the User can select an ID or activitycode (acode) the ...
0
votes
0answers
60 views

Multi-selection from Combo box in Python AddIn?

Is it possible to select more than one option from a combo box list in python Add ins for ArcGIS 10.x? Here is part of the code: def onFocus(self, focused): if focused: self....
21
votes
3answers
2k views

Running Python Script when opening MXD?

Can anyone tell me how to accomplish this? I want a Python script to run on opening the MXD which would pull an excel worksheet into a GDB and refresh the map. I only want this to happen in this ...
1
vote
1answer
120 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 ...
0
votes
1answer
77 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
0answers
17 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 ...
0
votes
1answer
39 views

Get filepath then append a feature class to that feature class Python Addins

I'm trying to use tool bar buttons (python addins) to add a filepath and then append another feature class (known to have identical schema, no test needed) to that filepath. My syntax isn't working ...
4
votes
3answers
398 views

ArcPy: Save and open mxd without closing ArcGIS

With Python Add-In Wizard I created a Button which: looks in a specific directory for the last created/modified folder (which is created with another tool) saves the current mxd with a new name in ...
1
vote
0answers
66 views

Python Addin - Run script from button [closed]

I'm developing a Python Addin for ArcMap. This will consist of a button that will run another python script: import arcpy from arcpy import env import pythonaddins import os class ButtonClass1(...
2
votes
2answers
243 views

python application extension onCreateFeature

Trying to populate certain attributes as soon as a feature is created. I have tried the python add-in application extension function "onCreateFeature", which does get triggered when a feature is ...
1
vote
2answers
180 views

Python Add-In Dialog with Textboxes in ArcPy?

With Python Add-In Wizard I created a ButtonTool with which I: click in the map get the coordinates of the mouseclick-location in a dialog with textboxes I want to receive the coordinates in a ...
1
vote
0answers
97 views

How to automatically run python code at the time when a mxd is saved?

I am trying to find a way to execute a few lines of (preferably python-)code whenever I save a specific mxd (my template.mxd) I'm working with arcgis desktop 10.3.1 (advanced, all extentions) What I ...
3
votes
0answers
42 views

Recovering toolbar from disconnected window?

I've faced this problem many times. I created a python addin toolbar and installed it in ArcGIS 10.2 . I work on dual monitors in the office. If accidentally this toolbox is left on the secondary ...
0
votes
1answer
77 views

Measure Point Along a Line

Looking to find Distance along a line(road) by a user input(Mouse Click). Here is my python code TESTED and works def onMouseDownMap(self, x, y, button, shift): mxd = arcpy.mapping.MapDocument("...
2
votes
1answer
44 views

Can tools or addins created in ArcMap be published and used in ArcGis Online?

I'm attempting to build an interactive map that would be hosted in AGOL. It would be a network query, whereupon selecting a point feature from an "inlet" layer, the map would display the corresponding ...
1
vote
1answer
107 views

QGIS docutils install (path,pythonpath,pythonhome)

New to QGIS and Python. Have QGIS installed and working great on Windows, want to install and use Docutils -- Python Documentation Utilities (presumably all simple and small .py programs). I see ...
1
vote
4answers
5k views

Synchronize Google Earth to ArcMap and vice versa

I found this old script that worked okay in 9.3, but since I've upgraded to 10.1 the VB code can't work. It basically allows you to quickly pan in Google Earth to find a feature, then you click on a ...
1
vote
1answer
98 views

How do I load a .shp file using a button with ArcPy?

I have created a python addin where the user should be able to select a shapfile and then load, but I've not been able to put in the current workspace. import arcpy import pythonaddins import os from ...
0
votes
0answers
55 views

Execute Built-In Command in ArcMap using Python Add-Ins Extension Event?

Is it possible to execute an ArcMap built-in command programmatically, using the Python Add-ins framework? Can ArcMap built-in commands be exposed to and executed using the event methods found in ...
6
votes
4answers
1k views

Code to open web browser crashes ArcMap when run from a Python add-in

I created an ArcMap Python add-in using ArcGIS 10.1 to open a webpage after the map is clicked. It opens the page but then ArcGIS crashes. import arcpy import pythonaddins import webbrowser class ...
7
votes
2answers
221 views

Installing an ArcGIS add-in on several PCs

I usually do my python scripts and add them to ArcMap in the form of add-ins. First I launch the ArcGIS Python Add-In Wizard, create a project, a toolbar and the tool. Then, every time I do an ...