Quantcast
Channel: Forums - Python
Browsing all 2485 articles
Browse latest View live

SearchCursor where clause

I a script that selections by location, but after that i need it to search the selected in the "Year" field anything >= to 2009, then copy those features out. Any help would be very appreciated. Her...

View Article


Edit legend label or description with python

Hi, In a nut shell, If anyone knows how to change the text in legend labels in arcpy let me know. This is what I have tried so far... I am trying to edit the description of the layer using the...

View Article


How to Set Feature Class/Layer Parameter Type

I'm not sure if it's really possible, but I'm trying to set a couple parameters in my ArcToolbox GUI. I know a few of the ArcGIS default tools do this, so I'm thinking I can. What I want for a...

View Article

netCDF4 and ArcGIS

I am having issues using the netCDF4 module within my python script for one of my ArcGIS tools. The weird thing is, the tool runs fine the first time, but then when I run the tool a second time I am...

View Article

Python Map Page Size

Can we set, and change, an .mxd page size using Python? I've seen several posts that all say no, but am hoping that some adept Python user has figured out how to do this (without using ArcObjects)....

View Article


ArcGIS Destop Geoprocessing Python - Changing DataFrameTime properties

I'm writing a script that adds a time enabled layer to a non-time aware dataframe. I want to be able to modify the start and end time of the dataframe and I've been using the cdde below but I'm getting...

View Article

Reg : Cursors on feature class and table participating in relationship class

Hello all , Is it possible to perform insert, update cursor on the feature class or tables in SDE which participates in relationship using arcpy 10.0 .I tried to perform insert cursor but it gave me...

View Article

Network Analyst Solve warnings

Hi, when scripting a Network analyst route solver tool is there a way to get the warnings from Solve to show by using arcpy.AddMessage(?). For instance when running solve from the network toolbar in...

View Article


Custom toolbar makes selection by series of ComboBox objects

Hello all- I'm working on a custom toolbar that will contain three combo boxes and one button. It will basically allow the user to select the layer (first combo box), the attribute (second combo box),...

View Article


Problem using .sde featureclass in the GetCount tool

My app needs to test the user-selected feature class for a selected set before it continues. The only method I have found in the forum to accomplish this is to use the GetCount function on the map...

View Article

Data Driven Page Text Element

I'm using a combination of data driven pages and a python script to populate text elements on a layout. I have a project set up with an index layer, and a mask layer. I also have a third layer...

View Article

Image may be NSFW.
Clik here to view.

Error 000582 - "Export to PDF" causing problems with "Select by Attribute"??

I've created a python script that manipulates a page layout so that I can export the view to a PDF. The code uses several different ""Select By Attribute" methods. My code operates as a function in a...

View Article

Connect script with a sub-menu entry within Python-Addin

I have created a menu entry using "pythonaddins" and it contains 2 sub-menus. Two separate scripts have to be linked to the sub-menus which should be invoked one-by-one when I click on sub-menu entry....

View Article


Last iteration of a loop

Hi, I would like to get the last iteration of a loop and do a calculate field on it ! I've try to catch the last iteration with this Code: if index !=len(fclist)-1:  or if index ==len(fclist)-1: But...

View Article

Import Metadata from an unformatted text file to a feature class

Hi all, I am looking to create a summary information to describe a feature class created within the script. The text file is not specifically formatted to follow any format (FGDC, ISO,...). I was...

View Article


beginner command/scripting/python help, 9.3

hi guys, long time lurker first time poster... if the information I'm after is already elsewhere, please point me in the right direction if it's faster. I've just started using arcgis 9.3 (no arcinfo)...

View Article

How to search for .mxd that contain a specific word within its filename

Hi, I'm fairly new to coding with Python. I have to walk through every folder and change the data source of all layers within each map document. But before doing so, I want to make a copy of each .mxd...

View Article


Adding a picture to layout

I am automating a series of maps and would like to add a picture symbol to the layout. I'm using Arc 10.1 if that makes a difference. I am pretty new to Python and am having a difficult time figuring...

View Article

python code

i have txt file that contains parcels with coordinates. and i want to do the following: Reads in an input text file (parcels.txt). The structure of the text file is the following: Feature: 0 (parcel...

View Article

Trouble with py2exe and arcpy / arcgisscripting

I'm trying to build an exe using py2exe. My script uses wxPython for a GUI, and arcpy for an Insert Cursor and an Update Cursor on one table inside of a personal gdb. I'm using ArcGIS 10.0 and Python...

View Article
Browsing all 2485 articles
Browse latest View live