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

Tkinter, ArcPy and Threading

Hey All, Just wanted to get a solid answer from someone. My question is very similar to: http://forums.arcgis.com/threads/633...py-in-a-thread (2012) I'm trying to intermittently inject data into an...

View Article


Copy Tables or Features Classes changes fieldnames that exceeds length of 28?!

Since 10.0 SP4 (until 10.1 SP1) i can't use arcpy.CopyRows_management or arcpy.CopyFeatures_management with fieldnames that exceeds 28 characters. These fieldname were change. Here some examples: Code:...

View Article


Image may be NSFW.
Clik here to view.

Add value to a field

Hi I was wondering if anyone can help me with some Python? I have a featuers Class with the columns KOMMUNE and GKR and some other columns.. Both columns are string. In the column KOMMUNE I have the...

View Article

run a model from python problem

I am using arcGIS 10.0 SP5 I have the following code : import arcpy arcpy.ImportToolbox(r"C:\Documents and Settings\Derek\FRAME\FORTEST.tbx", "Derek") arcpy.TEST_Derek() The model is names TEST The...

View Article

PYT: Change Symbology Based on User Selection

I have a Python toolbox that creates an output GPFeatureLayer from some analysis (that part works fine), but I also have a ValueList parameter with 3 options for how to symbolize the output. I point...

View Article


cursor dictionary help please

I need some help with arcpy.da.SearchCursor and dictionary. I currently have the old Search.Cursor here Code: # init rowW and rowR         curR = arcpy.SearchCursor(fcOutput)         join_dict =...

View Article

Python script field calculator skipping rows

I built a Python tool that uses Field Calculator to add and calculate a few different fields in a shapefile, including area as well as a few simple string variables based on user input. The function...

View Article

Import arcpy in 10.1

I've been shuffling along on multiple threads trying to find a solution to the "import arcpy" function. I'm not a programmer or do I understand python very well. I'm essentially trying to create a...

View Article


Easy points: Explain how I can use square brackets in a label expression.

I thought it would be easy to take a test table item with the format DEAN, JOHN, use a python expression split it at the comma and just use the last name for a label. I could condense the steps down to...

View Article


Populate an empty field in a road network

Hi, This is what I would like to achieve: Say I have a polygon layer that includes three cities 'X', 'Y', & 'Z' (in reality I have more than 1000s). I also have a road network layer. I want to...

View Article

Export PDF Bookmarks to PDF Pages (single PDF)

I have this script Code: import arcpy mxd = arcpy.mapping.MapDocument("I:\GIS_Workspace\MAP\Test.mxd") mainDF = arcpy.mapping.ListDataFrames(mxd, "Layers") [0]...

View Article

Issues with multiprocessing and spatial analyst

I have read every blog post and thread I can find on multiprocessing with arcpy and none of the fixes in them have fully addressed my problem. I'm trying to do a relatively simple watershed calculation...

View Article

InsertCursor into an SDE Feature Class (Point) in WebMercator Projection help

Hi, Setup: I have a SDE with a feature class created (in web Mercator projection). I'm trying to add new rows using arcpy and use the following (assume everything preceding this works fine)...

View Article


Command Prompt ArcGIS 10.2

In the past I have used command prompt to run batch files that consist of Python Commands with ArcGIS tools. From what I understand you are no longer able to do so with 10.2. Has anyone else...

View Article

Problem Deleting scratchGDB after script runs

I have a script running that does a bit of spatial analysis, creates a relationship table and exports layout images to JPEG for report. It runs great, but I am having a problem doing proper cleanup. I...

View Article


Synchronize Replica with a Geodataservice via REST?

I'm currently working on trying to find the best way to deploy a synchronize script to an application. I can create a model that synchs just fine in catalog that uses the connections created in...

View Article

Scratch Workspace?

I am writing a script and started reading through the docs for creating/setting a scratch workspace. So far, all I am getting out of it is that it is a place for temporal data and that it garantees...

View Article


arcapi - Convenient API for arcpy

Hello, Sometimes with arcpy I feel that to do little you need to write a lot. To make my life easier, I have written and documented a collection of functions, which are available as 'arcapi' on github:...

View Article

Specific bookmarks for arcpy.mapping.ListBookmarks

2 part question: 1. Trying to output a series of specific bookmarks to a pdf. I can do it with all bookmarks Code: for bkmk in arcpy.mapping.ListBookmarks(mxd,"*",df): or 1 specific bookmark Code: for...

View Article

Unable to run GIS tools that access arcpy

Hello, I've searched the discussion forums but have been unable to find a solution to my problem... I recently installed a new version of GIS (10.2). I had an old version of python (2.6) on my...

View Article
Browsing all 2485 articles
Browse latest View live