Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
A site-package created by Esri to expose ArcGIS Desktop (ArcMap and ArcGIS Pro) geoprocessing, mapping, etc, to Python.
1
vote
2
answers
228
views
Summarizing one field using another as summary statistic using ArcPy?
I'm trying to replicate, using arcpy, the 'right-click - Summarize' function in ArcMap.
I want to specifically summarize column 'A' of my attribute table (this is a point layer), to get the count. …
1
vote
1
answer
163
views
Setting scale for data driven pages
My code:
import arcpy
from arcpy import env
env.workspace = r"U:"
mxd = arcpy.mapping.MapDocument(r"U:\EMS.mxd")
df = arcpy.mapping.ListDataFrames(mxd)[0]
ddp = mxd.dataDrivenPages
indexLayer = ddp.indexLayer …
0
votes
1
answer
79
views
Add-In to Switch Selection [ArcMap 10.4]
My code:
import arcpy
import pythonaddins
class InverseSelection(object):
"""Implementation for RAFTv2_addin.invbtn (Button)"""
def __init__(self):
self.enabled = True
self.checked …
1
vote
Add-In to Switch Selection [ArcMap 10.4]
Ok, so I got it working
arcpy.SelectLayerByAttribute_management("buffcut", "SWITCH_SELECTION")
I needed to wrap buffcut with "". I thought setting it earlier on was the correct method but appare …
0
votes
1
answer
36
views
IndexError when adding multiple fields to shapefile
As part of a larger project i'm looking to add multiple fields to a shapefile using an index. This is the snippet in question:
listFields = [['ITEM', 'TEXT'], ['SYSTEM', 'TEXT'], ['WATERCOURCE_BANK', …
1
vote
1
answer
63
views
Text element name not appearing in ListLayoutElements
As in the title, I have the simple below code:
import arcpy
arcpy.env.workspace = r"U:"
mxd = arcpy.mapping.MapDocument(r"U:RAFT.mxd")
layoutlist = arcpy.mapping.ListLayoutElements(mxd, "TEXT_ELEMENT …
1
vote
0
answers
68
views
Creating Scale field based on polyline length (ArcMap)(Python)
What I have found so far is how to calculate it based on the difference between the length and height but this doesn't quite give the required results:
import arcpy
from arcpy import env
import os
env.workspace …