Created
December 12, 2013 17:12
-
-
Save antoniolocandro/7931540 to your computer and use it in GitHub Desktop.
Arcgis Python Codeblock / add autoIncrement() to Expression. Modified from http://forums.arcgis.com/threads/40981-Adding-to-fields-by-increments-of-1-in-the-Field-Calculator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rec=0 | |
def autoIncrement(): | |
global rec | |
pStart = 0 #adjust start value, if req'd | |
pInterval = 50 #adjust interval value, if req'd | |
if (rec == 0): | |
rec = pStart | |
else: | |
rec = rec + pInterval | |
return rec |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment