<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Node Dangles</title>
    <link>https://maprantala.com/</link>
    <description>Recent content on Node Dangles</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <lastBuildDate>Mon, 21 Jan 2019 05:19:03 -0600</lastBuildDate>
    <atom:link href="https://maprantala.com/index.xml" rel="self" type="application/rss+xml" />
    
    <item>
      <title>WordPress Permalinks Snafu</title>
      <link>https://maprantala.com/2019/01/21/wordpress-permalinks-snafu/</link>
      <pubDate>Mon, 21 Jan 2019 05:19:03 -0600</pubDate>
      <guid>https://maprantala.com/2019/01/21/wordpress-permalinks-snafu/</guid>
      <description>&lt;p&gt;Using a free &lt;a rel=&#34;noreferrer noopener&#34; aria-label=&#34; (opens in a new tab)&#34; href=&#34;http://statcounter.com/&#34; target=&#34;_blank&#34;&gt;StatCounter.com&lt;/a&gt; add-in, I get weekly emails showing the number of visitors to this blog. During the summer, the numbers plummeted. At the time, I thought it had to do with Google/Chrome requiring https.&lt;figure class=&#34;wp-block-image&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/stats.png?w=1170&amp;#038;ssl=1&#34; alt=&#34;&#34; class=&#34;wp-image-4844&#34; srcset=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/stats.png?w=546&amp;ssl=1 546w, https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/stats.png?resize=300%2C138&amp;ssl=1 300w&#34; sizes=&#34;(max-width: 546px) 100vw, 546px&#34; data-recalc-dims=&#34;1&#34; /&gt; &lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;Luckily, HostGator (disclosure: I&amp;rsquo;m working on becoming a HostGator affiliate), who I use to host this blog and a few other websites, provided free https certificates for all of my sites. So I made sure that &lt;a href=&#34;https://MapRantala.com&#34;&gt;https://MapRantala.com&lt;/a&gt; worked and thought the numbers would rebound.&lt;/p&gt;
&lt;p&gt;Looking at the chart, you can see they did only slightly. I assumed that it would just be a matter of time for Google to see that https was enabled and since the blog is more a place for me to make notes to myself, I wasn&amp;rsquo;t concerned.&lt;/p&gt;
&lt;p&gt;This weekend, I decided to take a look at Google&amp;rsquo;s Search Console and see if I could determine what was going on. Looking in the coverage, I saw many 404 results for pages. As I investigated some of them, I realized that it was due to my Permalinks setting.&lt;/p&gt;
&lt;p&gt;The URLs, as shown below, were not working.&lt;figure class=&#34;wp-block-image&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/404.jpg?w=1170&amp;#038;ssl=1&#34; alt=&#34;&#34; class=&#34;wp-image-4846&#34; srcset=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/404.jpg?w=836&amp;ssl=1 836w, https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/404.jpg?resize=300%2C198&amp;ssl=1 300w, https://i0.wp.com/maprantala.com/wp-content/uploads/2019/01/404.jpg?resize=768%2C506&amp;ssl=1 768w&#34; sizes=&#34;(max-width: 836px) 100vw, 836px&#34; data-recalc-dims=&#34;1&#34; /&gt; &lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;The website was using &amp;lsquo;&lt;a href=&#34;https://maprantala.com/index.php/&#39;&#34;&gt;https://maprantala.com/index.php/&#39;&lt;/a&gt; as the base URL. So, for example, &amp;lsquo;&lt;a href=&#34;https://maprantala.com/2017/08/07/arcgis-pro-2-0-migration-overview&#39;&#34;&gt;https://maprantala.com/2017/08/07/arcgis-pro-2-0-migration-overview&#39;&lt;/a&gt; did not work but &amp;lsquo;&lt;a href=&#34;https://maprantala.com/&#34;&gt;https://maprantala.com/&lt;/a&gt;&lt;strong&gt;index.php&lt;/strong&gt;/2017/08/07/arcgis-pro-2-0-migration-overview&amp;rsquo; did.&lt;/p&gt;
&lt;p&gt;To change the WordPress Permalinks setting, I went to Settings-Permalinks and removed he &amp;lsquo;index.php/&amp;rsquo; from the Custom Structure. Waiting a day, the 404s have disappeared in Search Console and, in theory, I just need to wait for Google to re-index the pages which are currently shown as &amp;lsquo;Crawled – currently not indexed&amp;rsquo;&lt;figure class=&#34;wp-block-image&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2019/01/permalinks.jpg?w=1170&amp;#038;ssl=1&#34; alt=&#34;Wordpress Permalinks Setting &#34; class=&#34;wp-image-4847&#34; srcset=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2019/01/permalinks.jpg?w=961&amp;ssl=1 961w, https://i2.wp.com/maprantala.com/wp-content/uploads/2019/01/permalinks.jpg?resize=300%2C45&amp;ssl=1 300w, https://i2.wp.com/maprantala.com/wp-content/uploads/2019/01/permalinks.jpg?resize=768%2C115&amp;ssl=1 768w&#34; sizes=&#34;(max-width: 961px) 100vw, 961px&#34; data-recalc-dims=&#34;1&#34; /&gt; &lt;figcaption&gt;WordPress Permalinks Setting &lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;That may not have been the whole problem. I republished this blog under a different name for a year. But moved it back to this domain when that domain registration expired. So that may have been another factor.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty: REST calls via python</title>
      <link>https://maprantala.com/2018/08/24/quick-dirty-rest-calls-via-python/</link>
      <pubDate>Fri, 24 Aug 2018 18:11:30 -0500</pubDate>
      <guid>https://maprantala.com/2018/08/24/quick-dirty-rest-calls-via-python/</guid>
      <description>&lt;p&gt;Was sharing a python script with a php developer to illustrate how a couple of requests can be made to an ArcGIS REST endpoint.&lt;/p&gt;
&lt;p&gt;Nothing fancy–one gets the data for one record, one gets data for all records, and the final gets the data for the record that intersects a point.&lt;/p&gt;
&lt;p&gt;The only thing to note is that the original version that I shared gets a token because the service it uses is secured. I commented out the routine to get a token and just substituted in a blank string and pointed the code at one of esri&amp;rsquo;s sample services at https://sampleserver6.arcgisonline.com/arcgis/.&lt;/p&gt;
&lt;p&gt;The file can be downloaded &lt;a href=&#34;https://github.com/MapRantala/Blog/blob/master/python/python/20180824_RESTRequests/sampleRESTRequests.py&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import requests, urllib, httplib, urllib2, json

serverURL = &#39;https://sampleserver6.arcgisonline.com/arcgis/&#39;
tokenURL =  serverURL+&amp;quot;tokens/&amp;quot;
phaseQueryURL = serverURL+&amp;quot;rest/services/Census/MapServer/3/query&amp;quot;

#Fields to be aware of:
# PhaseName = Name of the phase, a unique value.
# Status_Date = Date a phase was marked as &amp;quot;Live&amp;quot;
# PhaseStatus = Live, Provisioning, Pending

def makeRequest(inURL,inPayload):
    theRequest = urllib2.Request(url=inURL,data = urllib.urlencode(inPayload))
    theResponse = urllib2.urlopen(theRequest)
    responseString = theResponse.read()
    theJSON = json.loads(responseString)
    return theJSON

def getToken(inUser,inPass):
    inputData = {&#39;username&#39;:inUser,&#39;password&#39;:inPass, &#39;f&#39;:&#39;json&#39;}
    theJSON = makeRequest(tokenURL,inputData)
    print(theJSON)
    token = theJSON[&#39;token&#39;]
    return token

def queryAllStates(inToken):
    inputData = { &#39;where&#39;: &amp;quot;1=1&amp;quot;, &#39;f&#39;: &#39;geojson&#39;, &#39;outFields&#39;: &#39;*&#39; , &#39;outSR&#39;: 4326, &#39;token&#39;:inToken}
    theJSON = makeRequest(phaseQueryURL,inputData)
    return theJSON

def queryState(inPhase,inToken):
    inputData = { &#39;where&#39;: &amp;quot;STATE_NAME = &#39;{}&#39;&amp;quot;.format(inPhase), &#39;f&#39;: &#39;geojson&#39;, &#39;outFields&#39;: &#39;*&#39; , &#39;outSR&#39;: 4326, &#39;token&#39;:inToken}
    theJSON = makeRequest(phaseQueryURL,inputData)
    return theJSON

def findStateForPoint(inX,inY,inToken):
    inputData = {&#39;geometry&#39;: { &#39;x&#39;: inX, &#39;y&#39;: inY}, &#39;geometryType&#39;: &#39;esriGeometryPoint&#39;, &#39;inSR&#39;:4326, &#39;spatialRel&#39;:&#39;esriSpatialRelIntersects&#39;, &#39;outFields&#39;:&#39;*&#39;, &#39;f&#39;: &#39;json&#39;,&#39;token&#39;:inToken}

    theJSON = makeRequest(phaseQueryURL,inputData)
    return theJSON

username = &amp;quot;&amp;quot;
password = &amp;quot;&amp;quot;

##theToken = getToken(username,password)
theToken = &amp;quot;&amp;quot;
print(theToken)

#Attribute Query to get information about one State
stateInfo = queryState(&#39;Wisconsin&#39;,theToken)
print(stateInfo)

#Attribute Query to get information about all States
statesInfo = queryAllStates(theToken)
print(statesInfo)


#Find phase for a lat-lon
theState = findStateForPoint(-93.280842,44.95531,theToken)
print(theState)

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Forcing ArcGIS Online to Update Feature Layer Information</title>
      <link>https://maprantala.com/2018/06/22/forcing-arcgis-online-to-update-feature-layer-information/</link>
      <pubDate>Fri, 22 Jun 2018 20:26:28 -0500</pubDate>
      <guid>https://maprantala.com/2018/06/22/forcing-arcgis-online-to-update-feature-layer-information/</guid>
      <description>&lt;p&gt;Because we use ArcGIS Online Web Maps in our daily work-flows, I created an AGO group that contains Feature Layers that are links to our self-hosted ArcGIS Server services. This way, users can quickly add data from our ArcGIS Server Site and not have to look up URLs/Usernames/Passwords (I&amp;rsquo;ve save the username/password as part of the ArcGIS Online service when appropriate).&lt;/p&gt;
&lt;p&gt;But I&amp;rsquo;ve had a problem where if I change the service, the changes are not reflected in the AGO Feature Layer for that service and I have to monkey about to get the changes to migrate to the maps.&lt;/p&gt;
&lt;p&gt;Finally annoyed with doing that for the Xth time, I decided to see if I could get the feature service information to refresh automatically. Documentation search found nothing; call in to tech support–still waiting. While experimenting, however, I found that newer Feature Layer I added this way do actually update when I made changes. WTH?!&lt;/p&gt;
&lt;p&gt;Using &lt;a href=&#34;https://ago-assistant.esri.com/#&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;ArcGIS Online Assistant&lt;/a&gt;, something caught my eye. My older Feature Layers had a Description and Data but the newer (automatically updating ones) do not.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2018/06/Data-1.jpg&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;Was this the answer–the 912 line JSON file for this service had all the information about the Feature Service. So it seems like the information about my Feature Service probably got saved when I create the Feature Layer and this cache was used later instead of gathering new information. Now that I had a suspected reason why this was occurring, I needed to figure out how to either delete or force a refresh of the cache. There&amp;rsquo;s no delete option next to the Data section so I figured I would empty the content and see if that would work.&lt;/p&gt;
&lt;p&gt;&lt;span style=&#34;color: #ff0000;&#34;&gt;WARNING: Unsupported Technique Ahead!! Proceed at Own Risk–Test First with a Copy of Data!!!&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style=&#34;color: #000000;&#34;&gt;Using AGO Assistant, I copied the Feature Layer that did not recognize when I made changes to the Feature Service and then made a map with that new Feature Layer so that I could test against a copy of the data. Once I had those, I went to the Copy of my Feature Layer in AGO Assistant and deleted almost everything in the Data section and saved that. (Note that it despite saying it saved my edits when I deleted everything, the contents were still there so you have to leave something in there).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style=&#34;color: #000000;&#34;&gt; &lt;a href=&#34;https://i1.wp.com/maprantala.com/wp-content/uploads/2018/06/almostEmptyJSON.png&#34;&gt;&lt;img class=&#34;alignnone size-full wp-image-4787&#34; src=&#34;https://i1.wp.com/maprantala.com/wp-content/uploads/2018/06/almostEmptyJSON.png?resize=514%2C128&#34; alt=&#34;&#34; width=&#34;514&#34; height=&#34;128&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;/span&gt;&lt;br&gt;
Once I went and looked at the Feature Layer and it showed the layer I had previously added that was not showing up. And when added to a New map, it reflected all my changes. The existing map, however, still had previous settings–a new field, for example, did not appear.&lt;/p&gt;
&lt;p&gt;So I found a partial fix–the Feature Layer hopefully will not cache any information about the Feature Service so when I add it to a map, the most recent settings will be used. Will still need to update maps but at least I have a Feature Layer now that reflects the most recent changes to the Feature Service.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Using ArcPy.Mapping to update Definition Queries</title>
      <link>https://maprantala.com/2018/05/08/using-arcpy.mapping-to-update-definition-queries/</link>
      <pubDate>Tue, 08 May 2018 17:56:09 -0500</pubDate>
      <guid>https://maprantala.com/2018/05/08/using-arcpy.mapping-to-update-definition-queries/</guid>
      <description>&lt;p&gt;Working with a routine process today that I normally only do once in awhile but today needed to do it several times. It requires changing the definition query on several features classes. Being the &amp;lsquo;lazy&amp;rsquo; GIS guy that I am (owner of a company I used to work at called me that once as a sort of compliment for my tendency to script a lot of what I did), I decided to finally script it instead of changing definition queries about 42 times.&lt;/p&gt;
&lt;p&gt;The quick &amp;amp; dirty &lt;del&gt;script&lt;/del&gt; code that I wrote &amp;amp; can be run in the ArcMap python window consists of two parts. The first three lines just need to be run once per session to get a variable set with the list of layers. The loop I ran multiple times, updating the &amp;lsquo;.replace&amp;rsquo; settings each time. I ran the loop, did my other processes, and re-ran the loop as needed and was a happy GISer.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#These first 3 lines only need to be run once.
mxd = arcpy.mapping.MapDocument(&amp;quot;CURRENT&amp;quot;)
l = arcpy.mapping.ListDataFrames(mxd)[0] #Note the hard-code [0], meaning the first dataframe. YMMV
ll = arcpy.mapping.ListLayers(l)

#Everytime I wanted to update the definition queries just need to update the replace parameters.

for l in ll:
     try:
        print(l.name)
        print(l.definitionQuery)
        z = l.definitionQuery.replace(&amp;quot;_011&amp;quot;,&amp;quot;_012&amp;quot;)
        l.definitionQuery = z
     except:
        print(&amp;quot;&amp;quot;)

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>ArcToolbox Tool: Add [ST_CON_ABR] to Hennepin County, MN Centerlines</title>
      <link>https://maprantala.com/2017/10/04/arctoolbox-tool-add-st_con_abr-to-hennepin-county-mn-centerlines/</link>
      <pubDate>Wed, 04 Oct 2017 22:17:11 -0500</pubDate>
      <guid>https://maprantala.com/2017/10/04/arctoolbox-tool-add-st_con_abr-to-hennepin-county-mn-centerlines/</guid>
      <description>&lt;p&gt;One of the great advancements over the last decade plus in GIS is that government agencies have started to move away from a &amp;lsquo;recover-our-cost&amp;rsquo; mentality to more of an &amp;lsquo;Open Data&amp;rsquo;. Minnesota, for example, has launched their &lt;a href=&#34;https://gisdata.mn.gov/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Geospatial Commons&lt;/a&gt; as a platform for sharing data.&lt;/p&gt;
&lt;p&gt;And while getting free, authoritative data is awesome, it can leave you in a bind if the structure of the data changes. Sometime between April and September, Hennepin County, Minnesota, changed the schema of their &lt;a href=&#34;http://www.hennepin.us/gisopendata&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;publicly available street centerlines data&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The data used to have both a full, concatenated street name field ([ST_CONCAT]) and an abbreviated version ([ST_CON_ABR]). A record might have &amp;lsquo;James Lofton Avenue North&amp;rsquo; and &amp;lsquo;James Lofton Ave N&amp;rsquo;, respectively, in these two fields. The abbreviated version was nice for labeling but it disappeared from the most recent updates.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2017/10/Streetnames.jpg&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;So, as you  might guess from the fact that I&amp;rsquo;m posting about it, I wrote a script to add that field in and launch it from an ArcToolbox Tool. Nothing fancy going on in the code, just a series of replaces, depending on the field. Using dictionaries instead of arrays of paired values might have been better but the script takes just a few seconds to run so I can live with it as-is.&lt;/p&gt;
&lt;p&gt;The list of street type abbreviations came from a combination of &lt;a href=&#34;http://support.esri.com/en/technical-article/000008454&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;ESRI&amp;rsquo;s standards&lt;/a&gt; and those found in an older version of the Hennepin County data. There were no conflicting abbreviations between the two. The code warns if a street name occurs in the data that is not in the list.&lt;/p&gt;
&lt;p&gt;While I&amp;rsquo;m including the code here for reference, it&amp;rsquo;s probably best to &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/ArcToolbox/20171004_Add_STCONABR&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;download the code from GitHub.&lt;/a&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;#-------------------------------------------------------------------------------&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Name:        usi_dataprep_Add_STCONABR&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Purpose:     This can be used to add [CT_CON_ABR] to Hennepin County, MN&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#              centerlines. This is a concatenated, abbreviated full name of&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#              the street. This used to be included in the data but&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#              disappeared from the downloads in the summer of 2017.&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#              Data available at: http://www.hennepin.us/gisopendata&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Author:      mrantala&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Created:     2017.10.04&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#------------------------------------------------------------------------------&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy

&lt;span style=&#34;color:#75715e&#34;&gt;############################################&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;## Custom Variables&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#These are the fields that are concatenated. Hennepin has others but were always blank.&lt;/span&gt;
requiredFieldList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_PRE_DIR&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_PRE_TYP&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_NAME&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_TYP&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_DIR&amp;#34;&lt;/span&gt;]
&lt;span style=&#34;color:#75715e&#34;&gt;#This is the name of the field to add&lt;/span&gt;
newFieldName &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_CON_ABR&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#75715e&#34;&gt;#These are the abbreviations for [ST_POS_TYPE]. The list was created using a sample of&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin&amp;#39;s centerline data &amp;amp; Esri Tech article: http://support.esri.com/en/technical-article/000008454&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Note that I intentionally left cases in where there is no abbreviation (Fall, for example) as a means of&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#documenting the fact that it should NOT change.&lt;/span&gt;

abbList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Alcove&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Alcove&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Alley&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Aly&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Annex&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Anx&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Arcade&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Arc&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Avenue&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ave&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bay&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bay&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bayoo&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Byu&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Beach&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bch&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bend&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bnd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bluff&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Blf&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bluffs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Blfs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bottom&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Btm&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Boulevard&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Blvd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Branch&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Br&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bridge&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brook&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brooks&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brks&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Burg&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Burgs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bgs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bypass&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Byp&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Camp&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cp&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Canyon&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cyn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cape&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cpe&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Causeway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cswy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Center&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ctr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Centers&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ctrs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crossings&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crossings&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crossroad&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Xrd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Chase&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Chase&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Circle&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cir&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Circles&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cirs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cliff&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Clf&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cliffs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Clfs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Club&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Clb&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Close&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Close&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Common&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cmn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Commons&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cmns&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Corner&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cor&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Corners&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cors&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Corridor&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Corridor&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Course&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crse&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Court&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ct&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Courts&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cove&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cv&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Coves&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cvs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Creek&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crescent&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cres&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crest&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crst&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cross&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cross&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Crossing&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Xing&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Curve&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Curve&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dale&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dam&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dm&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Divide&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dv&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Down&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Down&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Downs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Downs&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Drive&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Drives&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Drs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Edge&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Edge&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Entry&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Entry&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Estate&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Est&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Estates&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ests&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Expressway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Expy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Extension&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ext&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Extensions&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Exts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fall&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fall&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Falls&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fls&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ferry&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fry&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Field&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fld&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fields&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Flds&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Flat&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Flt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Flats&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Flts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ford&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fords&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frds&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Forest&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frst&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Forge&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Forges&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frgs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fork&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Forks&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Frks&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fort&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ft&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Freeway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gables&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gables&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Garden&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gdn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gardens&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gdns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gate&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gate&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gateway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gtwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Glade&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Glade&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Glen&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Gln&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Glens&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Glns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Green&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Grn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Greens&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Grns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Greenway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Greenway&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Grove&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Grv&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Groves&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Grvs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Harbor&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hbr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Harbors&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hbrs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Haven&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hvn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Heights&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Highway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hill&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hills&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hls&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Hollow&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Holw&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Horn&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Horn&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Inlet&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Inlt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Island&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Is&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Islands&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Iss&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Isle&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Isle&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Junction&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Jct&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Junctions&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Jcts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Key&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ky&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Keys&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Kys&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Knoll&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Knl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Knolls&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Knls&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lake&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lakes&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lks&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Land&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Land&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Landing&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lndg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lane&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ln&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Light&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lgt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lights&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lgts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Loaf&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lf&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lock&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lck&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Locks&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lcks&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Lodge&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ldg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Loop&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Loop&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mall&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mall&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Manor&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mnr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Manors&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mnrs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Meadow&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mdw&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Meadows&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mdws&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mews&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mews&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mill&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ml&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mills&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mls&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mission&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Msn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Motorway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mtwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mount&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mountain&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mtn&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mountains&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Mtns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Neck&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Nck&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Orchard&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Orch&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Oval&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Oval&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Overpass&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Opas&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Park&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Park&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Parks&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Park&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Parkway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pkwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Parkways&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pkwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pass&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pass&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Passage&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Psge&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Path&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Path&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pike&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pike&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pine&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pne&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pines&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pnes&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Place&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Plain&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pln&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Plains&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Plns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Plaza&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Plz&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Point&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Points&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Port&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Prt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ports&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Prts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Prairie&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Pr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Radial&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Radl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Railroad&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Railroad&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ramp&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ramp&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ranch&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rnch&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rapid&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rpd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rapids&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rpds&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rest&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rst&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ridge&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rdg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ridges&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rdgs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rise&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rise&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;River&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Riv&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Road&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rd&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Roads&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rds&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Route&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rte&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Row&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Row&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rue&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Rue&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Run&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Run&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shoal&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shoals&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shls&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shore&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shr&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shores&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Shrs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Skies&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Skies&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Skyway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Skwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spring&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Springs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spgs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spur&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spur&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spurs&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Spur&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Square&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Sq&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Squares&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Sqrs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Station&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Sta&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Stravenue&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Stra&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Stream&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Strm&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Street&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;St&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Streets&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Sts&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Summit&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Smt&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Terrace&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ter&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Throughway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trwy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trace&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trce&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Track&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trak&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trafficway&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trfy&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trail&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Trl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Tunnel&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Tunl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Turn&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Turn&amp;#34;&lt;/span&gt;]) &lt;span style=&#34;color:#75715e&#34;&gt;#Hennepin Specific&lt;/span&gt;
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Turnpike&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Tpke&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Underpass&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Upas&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Union&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Un&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Unions&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Uns&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Valley&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vly&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Valleys&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vlys&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Viaduct&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Via&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;View&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vw&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Views&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vws&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Village&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vlg&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Villages&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vlgs&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ville&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vista&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Vis&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Walk&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Walk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Walks&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Walk&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Wall&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Wall&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Way&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Way&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ways&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Ways&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Well&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Wl&amp;#34;&lt;/span&gt;])
abbList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append([&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Wells&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Wls&amp;#34;&lt;/span&gt;])

&lt;span style=&#34;color:#75715e&#34;&gt;#List of changes for [St_POS_Dir]&lt;/span&gt;
posDirList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;North&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;N&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;East&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;E&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;South&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;S&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;West&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;W&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Northeast&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NE&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Northwest&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NW&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Southeast&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SE&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Southwest&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SW&amp;#34;&lt;/span&gt;]]
preDirList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;North&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;N&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;East&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;E&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;South&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;S&amp;#34;&lt;/span&gt;],[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;West&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;W&amp;#34;&lt;/span&gt;]]
&lt;span style=&#34;color:#75715e&#34;&gt;############################################&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;## Read Arguments&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (len(sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;):
    inFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]

&lt;span style=&#34;color:#75715e&#34;&gt;############################################&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# General Purpose Functions&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printit&lt;/span&gt;(inputString):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt;(inputString)
        arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(str(inputString))
    &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;pass&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printerror&lt;/span&gt;(inputString):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; (inputString)
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddError(inputString)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getField&lt;/span&gt;(inFeatureClass, inFieldName):
  fieldList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(inFeatureClass)
  &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iField &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; fieldList:
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; iField&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; inFieldName&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower():
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; iField
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; None

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;fieldExists&lt;/span&gt;(inFeatureClass, inFieldName):
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; getField(inFeatureClass,inFieldName) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&amp;gt;&lt;/span&gt; None

&lt;span style=&#34;color:#75715e&#34;&gt;############################################&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Initial QC&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;initialQC&lt;/span&gt;():
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(inFC)):
        printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;PASS: Feature Class {} Exists&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC))
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Feature Class {} Does Not Exist, Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFld &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; requiredFieldList:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (fieldExists(inFC,iFld)):
            printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;PASS: Feature Class {} Has Field [{}]&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC,iFld))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
            printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Feature Class {} Does Not Have Field [{}], Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC,iFld))
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (fieldExists(inFC,newFieldName)):
        printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;GOOD: Feature Class {} Does Not Already Have Field [{}]&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC,newFieldName))
        printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; ADDING Field [{}]&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(newFieldName))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
            arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddField_management(in_table&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;inFC, field_name&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;newFieldName, field_type&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;TEXT&amp;#34;&lt;/span&gt;, field_precision&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, field_scale&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, field_length&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;100&amp;#34;&lt;/span&gt;, field_alias&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, field_is_nullable&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NULLABLE&amp;#34;&lt;/span&gt;, field_is_required&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NON_REQUIRED&amp;#34;&lt;/span&gt;, field_domain&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)
        &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
            printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Error While Adding Field [{}], Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(newFieldName))
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (fieldExists(inFC,newFieldName)):
            printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Unable to Add Field [{}], Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(newFieldName))
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Feature Class {} Already Has Field [{}], Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFC,newFieldName))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True

&lt;span style=&#34;color:#75715e&#34;&gt;############################################&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Main&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;makeSubstitution&lt;/span&gt;(inList,inValue,inFieldName):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iAbbreviationPr &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; inList:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (inValue &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; iAbbreviationPr[&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;]): &lt;span style=&#34;color:#75715e&#34;&gt;#Found a Match&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; iAbbreviationPr[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;WARNING: [{}] of {} does not have a value in the abbreviation list! Potential Error...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inFieldName,inValue))
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; inValue

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;main&lt;/span&gt;():
    cursorFieldList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; requiredFieldList
    cursorFieldList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(newFieldName)

    &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
        iUCursor &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;da&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;UpdateCursor(inFC,cursorFieldList)
        iRowCount &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;
        iRowMax &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;
        &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; uRow &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; iUCursor:

            &lt;span style=&#34;color:#75715e&#34;&gt;#Just to give user an indicator that progress is being made&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iRowCount &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; iRowMax):
                printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; {}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iRowCount))
                iRowMax &lt;span style=&#34;color:#f92672&#34;&gt;*=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;
                iRowCount&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;

            abbreviateConcatenatedName &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;
            iFldIndex &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;
            &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFld &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; requiredFieldList:


                &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iFld &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; newFieldName):
                    uRow[iFldIndex] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; abbreviateConcatenatedName
                    iUCursor&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;updateRow(uRow)
                &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
                    iValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; uRow[iFldIndex]&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;strip() &lt;span style=&#34;color:#75715e&#34;&gt;#Strip is just a safe-guard&lt;/span&gt;


                    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; ((iValue &lt;span style=&#34;color:#f92672&#34;&gt;!=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;and&lt;/span&gt; (iValue &lt;span style=&#34;color:#f92672&#34;&gt;!=&lt;/span&gt; None)):
                        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iFld &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_PRE_DIR&amp;#34;&lt;/span&gt;):
                            iValue&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; makeSubstitution(preDirList,iValue,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_PRE_DIR&amp;#34;&lt;/span&gt;)
                        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iFld &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_TYP&amp;#34;&lt;/span&gt;):
                            iValue&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; makeSubstitution(abbList,iValue,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_TYPE&amp;#34;&lt;/span&gt;)
                        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iFld &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_DIR&amp;#34;&lt;/span&gt;):
                            iValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; makeSubstitution(posDirList,iValue,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ST_POS_DIR&amp;#34;&lt;/span&gt;)

                        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (abbreviateConcatenatedName &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;):
                            abbreviateConcatenatedName &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; iValue
                        &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
                            abbreviateConcatenatedName&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;iValue
                iFldIndex &lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;

        &lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; iUCursor
    &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;RuntimeError&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; e:
        printerror(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Error {} Occurred, Cancelling...&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(e))
        &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
            &lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; iUCursor
            &lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; uRow
        &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True


&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; __name__ &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;__main__&amp;#39;&lt;/span&gt;:
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (initialQC() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (main() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):
            printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Done!&amp;#34;&lt;/span&gt;)

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcGIS Pro 2.0 Migration Overview</title>
      <link>https://maprantala.com/2017/08/07/arcgis-pro-2.0-migration-overview/</link>
      <pubDate>Mon, 07 Aug 2017 19:48:08 -0500</pubDate>
      <guid>https://maprantala.com/2017/08/07/arcgis-pro-2.0-migration-overview/</guid>
      <description>&lt;p&gt;In April I started a new position at a company that had no existing GIS.&lt;/p&gt;
&lt;p&gt;Nothing.&lt;/p&gt;
&lt;p&gt;There was a definite need for GIS and some GIS-type functions were occuring but basically when I started, I had an &lt;a href=&#34;http://server.arcgis.com/en/server/latest/get-started/windows/what-is-arcgis-enterprise-.htm&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;ArcGIS Enterprise&lt;/a&gt; license and a mess of KML files.&lt;/p&gt;
&lt;p&gt;An exciting opportunity. And since I was starting from scratch, I had zero legacy concerns. No existing data, workflows, custom code, or maps to tie me to a specific software package. Knowing that ArcGIS Pro is taking over the world, I decided to transition to ArcPro and use that as our (GIS staff count of 1) company standard for desktop mapping.&lt;/p&gt;
&lt;p&gt;That plan got side-tracked somewhat when we purchased a data management tool (&lt;a href=&#34;http://crescentlink.com/products#manager&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;CrescentLink Network Manager&lt;/a&gt;) that is only available for ArcMap. But I have still been using Pro on a regular basis.&lt;/p&gt;
&lt;p&gt;I started a brilliant post about the transition–the pros, the cons, and my overall experience. But before I could finish it, &lt;a href=&#34;https://blogs.esri.com/esri/arcgis/2017/06/27/arcgis-pro-2-0-has-been-released/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;out came 2.0&lt;/a&gt; and my post was suddenly out-dated. So I&amp;rsquo;ve decided to split that post into a bunch of smaller, more focused posts.&lt;/p&gt;
&lt;h4 id=&#34;overview&#34;&gt;Overview&lt;/h4&gt;
&lt;p&gt;Without getting into to deep on specific features or functionality, I do have some broad comments to make.&lt;/p&gt;
&lt;h6 id=&#34;learning-curve&#34;&gt;Learning Curve&lt;/h6&gt;
&lt;p&gt;There is definitely a learning curve in moving from ArcGIS Desktop to ArcGIS Pro–even though there is a lot of the same concepts between Pro &amp;amp; Desktop (the Toolboxes have barely changed), just finding the tools was a huge hurdle at first. I&amp;rsquo;ve never been a fan of the ribbon interface, I like my tools to be where they are and accessible.&lt;/p&gt;
&lt;p&gt;But with regular use, I have gotten more adept at finding what I want to use. Still end up hunting for tools at times but it has gotten better. I&amp;rsquo;m probably at about 75% efficiency as compared to Desktop although I switch between the two on a regular basis because there are times where I just need to get something done.&lt;/p&gt;
&lt;h6 id=&#34;stability&#34;&gt;Stability&lt;/h6&gt;
&lt;p&gt;Even though I just had to force-stop a session, 2.0 has made significant strides in stability. I had near daily crashes with 1.5 but now it is maybe a once-a-week. Maybe I&amp;rsquo;ve learned what not to do in Pro but I don&amp;rsquo;t remember any pattern to the crashes I had with 1.5.&lt;/p&gt;
&lt;h6 id=&#34;performance&#34;&gt;Performance&lt;/h6&gt;
&lt;p&gt;Performance is still painful to me. There are too many times when the wait cursor shows up when you do simple things like clicking on a button. A lot of the processing has been routed through the geoprocessing system and it just seems much slower.&lt;/p&gt;
&lt;h4 id=&#34;version-20-highlights&#34;&gt;Version 2.0 Highlights&lt;/h4&gt;
&lt;p&gt;While I&amp;rsquo;ll probably do some whining about ArcGIS Pro in this planned series of posts, there were a couple of significant highlights to the 2.0 release that took care of two of my major usability concerns.&lt;/p&gt;
&lt;li style=&#34;list-style-type: none;&#34;&gt;
  &lt;ul&gt;
    &lt;li&gt;
      Simultaneously running multiple instances of ArcGIS on the same machine. I did some initial scripting for a data preparation process. The script took a good 15-20 minutes to run. Using 1.5, I had to launch it and then work in something other than ArcGIS Pro. Now I can launch that process and continue to work in a second session.
    &lt;/li&gt;
    &lt;li&gt;
      Highlighting. Maybe I am just weird but I really missed the ability to highlight records in table. As part of my QC process, I will often select records using a spatial or attribute query and then go through that set and either unselect or reselect them in batches by first highlighting them. This was a huge issue I had with 1.5 especially since it does not seem like it should be difficult functionality to add in. I was going to wait on 2.0 until I saw this functionality.&lt;a href=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2017/08/Highlight-1.png&#34;&gt;&lt;img class=&#34;aligncenter wp-image-4715 &#34; src=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2017/08/Highlight-1.png?resize=886%2C374&#34; alt=&#34;&#34; width=&#34;886&#34; height=&#34;374&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;
    &lt;/li&gt;
  &lt;/ul&gt;
&lt;/li&gt;
&lt;h4 id=&#34;summary&#34;&gt;Summary&lt;/h4&gt;
&lt;p&gt;Overall, I&amp;rsquo;ve grown accustom to ArcPro. Like any new software, it takes time to get a feel for it. The transition is not that much different from going from ArcView 3.x to ArcGIS Desktop (or whatever 8.x was called). I am not yet as productive in it as Desktop but there are some things I really like about it to go along with my complaints.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Esri Web AppBuilder 2.4, Empty Basemap Gallery Follow-Up</title>
      <link>https://maprantala.com/2017/08/06/esri-web-appbuilder-2.4-empty-basemap-gallery-follow-up/</link>
      <pubDate>Sun, 06 Aug 2017 10:12:07 -0500</pubDate>
      <guid>https://maprantala.com/2017/08/06/esri-web-appbuilder-2.4-empty-basemap-gallery-follow-up/</guid>
      <description>&lt;p&gt;A while ago I &lt;a href=&#34;https://maprantala.com/2017/04/10/esri-web-appbuilder-2-4-empty-basemap-gallery/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;posted &lt;/a&gt;a work-around for a problem I was having with a &lt;a href=&#34;http://www.esri.com/software/web-appbuilder&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Web AppBuilder&lt;/a&gt; application. Working with Esri tech support, we determined what I was doing to cause the problem.&lt;/p&gt;
&lt;p&gt;In my config.json, I was using a relative path to the proxy. Note that I had the proxy as a separate application at the root level of our domain because I intended to have a shared proxy for all of our applications instead of individual ones. So the WAB application would be using &lt;a href=&#34;http://ourarcgisdomain.com/proxy/proxy.ashx&#34;&gt;http://ourarcgisdomain.com/proxy/proxy.ashx&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;quot;httpProxy&amp;quot;: {
	&amp;quot;useProxy&amp;quot;: true,
	&amp;quot;alwaysUseProxy&amp;quot;: true,
    &amp;quot;url&amp;quot;: &amp;quot;/proxy/proxy.ashx&amp;quot;,
    &amp;quot;rules&amp;quot;: []
  }

&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Well, that was causing the hiccup in the &lt;a href=&#34;http://doc.arcgis.com/en/web-appbuilder/create-apps/widget-basemap.htm&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Basemap Gallery Widget&lt;/a&gt;. I simply modified the url parameter to have the full path of our domain, undid my custom code, and the Basemap Gallery Widget was happy.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;quot;httpProxy&amp;quot;: {
     &amp;quot;useProxy&amp;quot;: true,
     &amp;quot;alwaysUseProxy&amp;quot;: true,
     &amp;quot;url&amp;quot;: &amp;quot;http://ourarcgisdomain.com/proxy/proxy.ashx&amp;quot;,
     &amp;quot;rules&amp;quot;: []
   }

&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Score one for Esri Tech Support.&lt;/p&gt;
&lt;p&gt;Although, in my defense the &lt;a href=&#34;https://developers.arcgis.com/web-appbuilder/api-reference/app-configuration.htm&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;documentation on the configuring the proxy&lt;/a&gt; is silent on the pathing.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Esri Web AppBuilder 2.4 Empty Basemap Gallery</title>
      <link>https://maprantala.com/2017/04/10/esri-web-appbuilder-2.4-empty-basemap-gallery/</link>
      <pubDate>Mon, 10 Apr 2017 20:08:37 -0500</pubDate>
      <guid>https://maprantala.com/2017/04/10/esri-web-appbuilder-2.4-empty-basemap-gallery/</guid>
      <description>&lt;p&gt;I recently downloaded Web AppBuilder 2.4, Developer&amp;rsquo;s Edition and built a quick &amp;amp; dirty app. For some reason, it worked fine in Web AppBuilder but once I deployed it, no basemaps would show in the &lt;a href=&#34;http://doc.arcgis.com/en/web-appbuilder/create-apps/widget-basemap.htm&#34;&gt;Basemap Gallery widget&lt;/a&gt;, it would just spin, spin, spin.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2017/04/BasemapGallery.png&#34; alt=&#34;Basemap Gallery&#34;&gt;&lt;/p&gt;
&lt;p&gt;Digging around, I found some &lt;a href=&#34;https://geonet.esri.com/thread/118906&#34;&gt;old posts&lt;/a&gt; where users were experiencing similar problems but none of the solution resulted in a great solution. I was able to get it to work by listing the basemaps individually in the config_BasemapGallery.json file but I that was more of a work-around. Notice in the thumbnailUrl, I have to put the full path to the thumbnails. Note that for brevity&amp;rsquo;s sake, I&amp;rsquo;m only showing one of the basemaps in this sample.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;{
  &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;basemapGallery&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; {
    &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;showArcGISBasemaps&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;true&lt;/span&gt;,
    &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;basemaps&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; [{
      &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;layers&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; [{&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;url&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;http://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer&amp;#34;&lt;/span&gt;}],
      &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;title&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Imagery&amp;#34;&lt;/span&gt;,
      &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;thumbnailUrl&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;http://&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/content/items/&amp;lt;id&amp;gt;/info/thumbnail/tempimagery.jpg&amp;#34;&lt;/span&gt;,
      &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;spatialReference&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; {
         &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;wkid&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;102100&amp;#34;&lt;/span&gt;
      }
     }]
   }
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Eventually, I started comparing the requests generated by the version in the development version and the one in production and tracked the problem down to this POST request in production, which was returning a 400 Bad Request error:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;http&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;//&amp;lt;server&amp;gt;/proxy/proxy.ashx?https://&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/search&amp;amp;wab_dv=2.4
&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;To this one in dev:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;https&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;//&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/search
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I stripped off the &amp;lsquo;&amp;amp;wab_dv=2.4&amp;rsquo; parameter from the production request and Boom! it worked. So I now knew what was causing the problem. Just had to figure out why it was occurring. I had actually already seen part of the answer while digging around in &lt;strong&gt;env.js&lt;/strong&gt; while looking for a way to test my changes without having to clear my cache or remember to use an Incognito session. On line 81 of &lt;strong&gt;env.js&lt;/strong&gt;, there is this variable, &lt;strong&gt;deployVersion&lt;/strong&gt; which is set to 2.4.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images//2017/04/deployVersion.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;I had recently worked on a solution that involved appending a time stamp onto scripts we were loading so I was familiar with what is going on–the code was appending a version onto the call so that if you change the &lt;strong&gt;deployVersion&lt;/strong&gt;, the browser would load a new version of the code. The &lt;strong&gt;appendDeployVersion&lt;/strong&gt; function on line 307 of &lt;strong&gt;env.js&lt;/strong&gt; was doing the append. Notice the &lt;strong&gt;if&lt;/strong&gt; statement on line 312, it checks for &amp;lsquo;?&amp;rsquo; in the url. If it finds one, it appends &amp;lsquo;**&amp;amp;&lt;strong&gt;wab_dv=&amp;rsquo; and the version, otherwise it appends &amp;lsquo;&lt;/strong&gt;?**wab_dv=&amp;rsquo; and the version–the difference being the &amp;lsquo;&amp;amp;&amp;rsquo; vs &amp;lsquo;?&amp;rsquo;. A question mark is used before the first parameter in an URL, each additional parameter is separated by a ampersand (&amp;amp;) so that logic makes sense.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2017/04/IfStatement.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;However, the monkey wrench is that I&amp;rsquo;m using a proxy, so my URL has a question mark related to the proxy:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;http&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;//&amp;lt;server&amp;gt;/proxy/proxy.ashx&amp;lt;strong&amp;gt;?&amp;lt;/strong&amp;gt;https://&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/search&amp;amp;wab_dv=2.4
&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;So the code was dutifully appending an ampersand and the version parameter &amp;lsquo;&amp;amp;wab_dv=2.4&amp;rsquo; to my URL so the proxy would be requesting:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;https&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;//&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/search&amp;amp;wab_dv=2.4
&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;when it should have been requesting:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;https&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;//&amp;lt;org&amp;gt;.maps.arcgis.com/sharing/rest/search?wab_dv=2.4
&lt;/span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Once I had determined the problem (99% of the battle), I was able to quickly put in a patch that works for my instance. This patch isn&amp;rsquo;t a great one that Esri should use but it solves it in my case. I just added logic so that it would ignore proxy-related question marks:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2017/04/solution.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;function&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;appendDeployVersion&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;){
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;/^http(s)?:\/\//&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;test&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;||&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;/^\/proxy\.js/&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;test&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;||&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;/^\/\//&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;test&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;)){
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;;
    }

	&lt;span style=&#34;color:#66d9ef&#34;&gt;var&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;proxyURL&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;toLowerCase&lt;/span&gt;().&lt;span style=&#34;color:#a6e22e&#34;&gt;replace&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;.ashx?&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;);
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;proxyURL&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;indexOf&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;?&amp;#39;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;){
      &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&amp;amp;wab_dv=&amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;deployVersion&lt;/span&gt;;
    }&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;{
      &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;?wab_dv=&amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;deployVersion&lt;/span&gt;;
    }
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;;
  }

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And voila! my Web AppBuilder now had all the basemaps options a mapineer could hope for:&lt;br&gt;
&lt;img src=&#34;https://maprantala.com/images/2017/04/BaemapsAplenty.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>2016 Grandma&#39;s Marathon Map</title>
      <link>https://maprantala.com/2016/05/16/2016-grandmas-marathon-map/</link>
      <pubDate>Mon, 16 May 2016 23:26:12 -0500</pubDate>
      <guid>https://maprantala.com/2016/05/16/2016-grandmas-marathon-map/</guid>
      <description>&lt;p&gt;A Little Map I made for fun for Grandma&amp;rsquo;s Marathon ( &lt;a href=&#34;https://twitter.com/grandmasmara&#34;&gt;@grandmasmara&lt;/a&gt; ) or click &lt;a href=&#34;http://GrandmasMarathonMap.Com/&#34; target=&#34;_blank&#34;&gt;Here &lt;/a&gt;for the stand-alone map.&lt;/p&gt;
&lt;!-- iframe plugin v.4.5 wordpress.org/plugins/iframe/ --&gt;</description>
    </item>
    
    <item>
      <title>Converting MXD to Layer file in Arcpy</title>
      <link>https://maprantala.com/2015/08/14/converting-mxd-to-layer-file-in-arcpy/</link>
      <pubDate>Fri, 14 Aug 2015 10:01:54 -0500</pubDate>
      <guid>https://maprantala.com/2015/08/14/converting-mxd-to-layer-file-in-arcpy/</guid>
      <description>&lt;p&gt;Working on doing some &lt;a href=&#34;http://resources.arcgis.com/EN/HELP/MAIN/10.1/index.html#//01540000056t000000&#34; target=&#34;_blank&#34;&gt;advanced ArcGIS server printing&lt;/a&gt; and had the need to batch convert many existing .mxd files to .lyr files. So instead of opening up X number of map documents, thought I would do it via code. All of my .mxds in this case had just one data frame so the process was pretty simple–I add an empty group layer (Thanks &lt;a href=&#34;http://gis.stackexchange.com/users/434/petr-krebs&#34; target=&#34;_blank&#34;&gt;Petr Krebs&lt;/a&gt; for the idea), copy all the existing layers into it, and save it out as a layer file.&lt;/p&gt;
&lt;p&gt;I created an ArcGIS toolbox with two options–one to convert a single .mxd and one to batch convert an entire folder. To use it, make sure to have the EmptyGroup.lyr in the same directory as the .py file.&lt;/p&gt;
&lt;p&gt;Here is the raw code or &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/ArcToolbox/ArcGIS/20150814_ConvertMxd2Lyr&#34; target=&#34;_blank&#34;&gt;git it&lt;/a&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import os
import arcpy
import inspect
import glob
import uuid
import inspect

codeDir = os.path.dirname(inspect.getfile(inspect.currentframe()))
EmptyGroupLayerFile = codeDir+&amp;quot;/EmptyGroup.lyr&amp;quot;
inArg1 = sys.argv[1]
inArg2 = sys.argv[2]

def printit(inMessage):
    arcpy.AddMessage(inMessage)

def makeLyrFromMXD(inMXD, outLyr):
    if not (os.path.exists(inMXD)):
        printit( &amp;quot;ERROR: {} does not exist&amp;quot;.format(inMXD))
        return False
    if not (os.path.exists(EmptyGroupLayerFile)):
        printit( &amp;quot;ERROR: {} does not exist&amp;quot;.format(EmptyGroupLayerFile))
        return False
    if  (os.path.exists(outLyr)):
        printit( &amp;quot;Skipping: {} already exists&amp;quot;.format(outLyr))
        return True

    printit( &amp;quot;Making Layer file: {0}&amp;quot;.format(outLyr))

    mxd = arcpy.mapping.MapDocument(inMXD)
    ###Right now, just doing the first Dataframe, this could be modified
    df = arcpy.mapping.ListDataFrames(mxd)[0]

    theUUID = str(uuid.uuid1())

    iGroupLayerRaw = arcpy.mapping.Layer(EmptyGroupLayerFile)
    iGroupLayerRaw.name = theUUID
    arcpy.mapping.AddLayer(df,iGroupLayerRaw,&amp;quot;TOP&amp;quot;)
    groupBaseName = os.path.basename(outLyr).split(&amp;quot;.&amp;quot;)[0]

    for lyr in arcpy.mapping.ListLayers(df):
        if not (lyr.name == theUUID):
            if (lyr.longName == lyr.name):
                arcpy.mapping.AddLayerToGroup (df, iGroupLayer, lyr, &amp;quot;Bottom&amp;quot;)
        else:
            iGroupLayer = lyr

    iGroupLayer.name = groupBaseName
    arcpy.SaveToLayerFile_management(iGroupLayer, outLyr)
    return os.path.exists(outLyr)

def doMultiple(inDir,outDir):
    for iMxd in glob.glob(inDir+&amp;quot;/*.mxd&amp;quot;):
        lyrFile = outDir+&amp;quot;/&amp;quot;+os.path.basename(iMxd).lower().replace(&amp;quot;.mxd&amp;quot;,&amp;quot;.lyr&amp;quot;)
        makeLyrFromMXD(iMxd, lyrFile)

if(not os.path.exists(EmptyGroupLayerFile)):
    printit(&amp;quot;Error: {} is missing, can not run.&amp;quot;.format(EmptyGroupLayerFile))
else:
    if (os.path.isdir(inArg1) and (os.path.isdir(inArg2))):
        doMultiple(inArg1,inArg2)
    elif (os.path.isfile(inArg1)):
        if (os.path.exists(inArg2)):
            printit(&amp;quot;Error: {} already exists&amp;quot;.format(inArg2))
        else:
            makeLyrFromMXD(inArg1,inArg2)
    else:
        printit(&amp;quot;Unable to understand input parameters&amp;quot;)

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Calling os.startfile and webbrowser.open from ArcGIS</title>
      <link>https://maprantala.com/2014/12/31/calling-os.startfile-and-webbrowser.open-from-arcgis/</link>
      <pubDate>Wed, 31 Dec 2014 14:38:16 -0600</pubDate>
      <guid>https://maprantala.com/2014/12/31/calling-os.startfile-and-webbrowser.open-from-arcgis/</guid>
      <description>&lt;p&gt;Recently I&amp;rsquo;ve created &lt;a href=&#34;http://resources.arcgis.com/en/help/main/10.2/index.html#//014p00000025000000&#34; target=&#34;_blank&#34;&gt;Python add-ins&lt;/a&gt; for data entry for our staff. Most of these have a toolbar with a &amp;lsquo;Help&amp;rsquo; button that opens a help file in .pdf format.&lt;figure id=&#34;attachment_4515&#34; aria-describedby=&#34;caption-attachment-4515&#34; style=&#34;width: 339px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/12/Toolbar.png&#34; alt=&#34;Sample python add-in toolbar.&#34;&gt;&lt;/p&gt;
&lt;figcaption id=&#34;caption-attachment-4515&#34; class=&#34;wp-caption-text&#34;&gt;Sample python add-in toolbar.&lt;/figcaption&gt;&lt;/figure&gt; 
&lt;p&gt;The first add-in was for ArcCatalog and this worked splendidly. I was using os.startfile(&lt;em&gt;path to help.pdf&lt;/em&gt;).&lt;/p&gt;
&lt;p&gt;However, when I started doing ArcMap add-ins, clicking the Help button would open the help.pdf but ArcMap would crash. Oops!&lt;/p&gt;
&lt;p&gt;Luckily the &lt;a href=&#34;https://twitter.com/arcpy&#34; target=&#34;_blank&#34;&gt;Python development team at Esri&lt;/a&gt; already had a &lt;a href=&#34;https://arcpy.wordpress.com/2013/10/25/using-os-startfile-and-webbrowser-open-in-arcgis-for-desktop/&#34; target=&#34;_blank&#34;&gt;blog post&lt;/a&gt; about this at their &lt;a href=&#34;https://arcpy.wordpress.com/&#34; target=&#34;_blank&#34;&gt;ArcPy Café blog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;They report that the root of the problem is &amp;lsquo;conflicts in the way the Windows libraries expect to be called, they can fail or crash when called within ArcGIS for Desktop in an add-in script or geoprocessing script tool&amp;rsquo;. But this can be overcome by using a &lt;a href=&#34;http://en.wikipedia.org/wiki/Decorator_pattern&#34; target=&#34;_blank&#34;&gt;decorator&lt;/a&gt; function that calls os.startfile from a new thread. Another function effected by these conflicts is webbrowser.open.&lt;/p&gt;
&lt;p&gt;Example code is shown below:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; functools
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; threading
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; webbrowser
 
&lt;span style=&#34;color:#75715e&#34;&gt;# A decorator that will run its wrapped function in a new thread&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;run_in_other_thread&lt;/span&gt;(function):
    &lt;span style=&#34;color:#75715e&#34;&gt;# functool.wraps will copy over the docstring and some other metadata&lt;/span&gt;
    &lt;span style=&#34;color:#75715e&#34;&gt;# from the original function&lt;/span&gt;
    &lt;span style=&#34;color:#a6e22e&#34;&gt;@functools.wraps&lt;/span&gt;(function)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;fn_&lt;/span&gt;(&lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt;args, &lt;span style=&#34;color:#f92672&#34;&gt;**&lt;/span&gt;kwargs):
        thread &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; threading&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Thread(target&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;function, args&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;args, kwargs&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;kwargs)
        thread&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;start()
        thread&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;join()
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; fn_
 
&lt;span style=&#34;color:#75715e&#34;&gt;# Our new wrapped versions of os.startfile and webbrowser.open&lt;/span&gt;
startfile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; run_in_other_thread(os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;startfile)
openbrowser &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; run_in_other_thread(webbrowser&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;open)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then whenever you call startfile or openbrowser, it will be routed through your decorator function and, as far as I&amp;rsquo;ve been able to tell, works fine without crashing your ArcMap session.&lt;/p&gt;
&lt;p&gt;Cheers!&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty Arcpy: Verify a Coded Value Domain Code</title>
      <link>https://maprantala.com/2014/12/18/quick-dirty-arcpy-verify-a-coded-value-domain-code/</link>
      <pubDate>Thu, 18 Dec 2014 22:32:11 -0600</pubDate>
      <guid>https://maprantala.com/2014/12/18/quick-dirty-arcpy-verify-a-coded-value-domain-code/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been working on a few different data import routines and one of the things I recently built was the ability to verify that a potential Code to be entered into a field with a &lt;a href=&#34;http://resources.arcgis.com/en/help/main/10.2/index.html#//001s00000001000000&#34; target=&#34;_blank&#34;&gt;Coded Value Domain&lt;/a&gt; is valid.&lt;/p&gt;
&lt;p&gt;The logic of the code is pretty straight-forward. Get a field&amp;rsquo;s domain and check that a potential value is one of the code values. The biggest &amp;lsquo;trick&amp;rsquo; in this code is that &lt;a href=&#34;http://resources.arcgis.com/en/help/main/10.2/index.html#//018w0000001z000000&#34; target=&#34;_blank&#34;&gt;arcpy.da.ListDomains&lt;/a&gt;, which locates a field&amp;rsquo;s domain, takes a geodatabase (or Enterprise geodatabase connection file) as its only parameter. The documentation says it takes a workspace, but it does not like a feature dataset, which a feature class might be in.&lt;/p&gt;
&lt;p&gt;A couple caveats about the code. It only returns True if a field exists, has a coded value domain, and the value tested is one of the (case-sensitive) valid codes. While I have an ArcToolbox tool to call it for illustration purposes, I&amp;rsquo;m only calling it from code so I wanted tight requirements.&lt;/p&gt;
&lt;p&gt;Anyhow, here is the code or &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/python/arcpy/20141218_VerifyDomainValue&#34; target=&#34;_blank&#34;&gt;download it&lt;/a&gt; from GitHub.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy

inFeatureClass &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
inField &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]
inValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;]

&lt;span style=&#34;color:#75715e&#34;&gt;# getFeatureClassParentWorkspace: This script gets the geodatabase for a&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# feature class. The trick here is that feature classes can be within a&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# feature dataset so you need to account for two possible levels in the&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# directory structure.&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getFeatureClassParentWorkspace&lt;/span&gt;(inFeatureClass):
    describeFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Describe(inFeatureClass)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (describeFC&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataType &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;FeatureClass&amp;#39;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;or&lt;/span&gt; (describeFC&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataType &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Table&amp;#39;&lt;/span&gt;):
        workspace1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; describeFC&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path
        describeWorkspace1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Describe(workspace1)
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (describeWorkspace1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataType &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;FeatureDataset&amp;#39;&lt;/span&gt;):
            &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; describeWorkspace1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path
        &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; workspace1

    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; None

&lt;span style=&#34;color:#75715e&#34;&gt;# Find a field within a feature class&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getField&lt;/span&gt;(inFeatureClass, inFieldName):
  fieldList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(inFeatureClass)
  &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iField &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; fieldList:
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; iField&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; inFieldName&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower():
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; iField
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; None

&lt;span style=&#34;color:#75715e&#34;&gt;#Get a field&amp;#39;s domain&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getDomain&lt;/span&gt;(inFeatureClass, inField):
    theField &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; getField(inFeatureClass,inField)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (theField &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&amp;gt;&lt;/span&gt; None):
        searchDomainName &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; theField&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (searchDomainName &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;):
            &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iDomain &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;da&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListDomains(getFeatureClassParentWorkspace(inFeatureClass)):
                &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; iDomain&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; searchDomainName:
                    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; iDomain
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; None

&lt;span style=&#34;color:#75715e&#34;&gt;#Get the domain.&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;validDomainValue&lt;/span&gt;(inFeatureClass,inField,inValue):
    theDomain &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; getDomain(inFeatureClass,inField)

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (theDomain &lt;span style=&#34;color:#f92672&#34;&gt;is&lt;/span&gt; None):
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (theDomain&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domainType &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;CodedValue&amp;#34;&lt;/span&gt;):
            &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; theDomain&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;codedValues&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;has_key(inValue):
                &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (validDomainValue(inFeatureClass,inField,inValue)):
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Value ({0}) is valid for field [{1}].&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inValue,inField))
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddError(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ERROR: Value ({0}) is invalid for field [{1}].&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(inValue,inField))

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty ArcPy: Listing Data Sources</title>
      <link>https://maprantala.com/2014/12/03/quick-dirty-arcpy-listing-data-sources/</link>
      <pubDate>Wed, 03 Dec 2014 08:05:10 -0600</pubDate>
      <guid>https://maprantala.com/2014/12/03/quick-dirty-arcpy-listing-data-sources/</guid>
      <description>&lt;p&gt;I just had the need to go through a directory containing many (100+) layer files (.lyr) and verify the data sources in each. I could have loaded each into ArcMap and checked the properties, but choose not to. Here&amp;rsquo;s the &lt;a href=&#34;https://github.com/MapRantala/Blog/blob/master/python/arcpy/20141203_ListDataSources/listDataSources.py&#34;&gt;bare-bones script&lt;/a&gt; I used instead:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt;os

theDir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;r&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;L:\gdrs\data\org\us_mn_state_dnr\elev_minnesota_lidar&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\\&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;
os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;chdir(theDir)

&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFile &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;glob(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;*.lyr&amp;#34;&lt;/span&gt;):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; iFile
    lyr &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;mapping&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Layer(iFile)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; i &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;mapping&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListLayers(lyr):
        &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
            &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;    {0}: {1}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(i,i&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataSource)
        &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
            &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;    {0}: Does not support dataSource&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(i)

&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Done!&amp;#34;&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Python Nulls (None)</title>
      <link>https://maprantala.com/2014/10/10/arcmap-field-calculator-python-nulls-none/</link>
      <pubDate>Fri, 10 Oct 2014 14:22:40 -0500</pubDate>
      <guid>https://maprantala.com/2014/10/10/arcmap-field-calculator-python-nulls-none/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been asked this twice this week, so thought I should post it. Calculating Null values in the ArcMap Field Calculator is easy, if you can remember the right work for &amp;lsquo;Null&amp;rsquo;. The proper word is &amp;lsquo;None&amp;rsquo; (without the quotes). Good luck &amp;amp; have a good weekend.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2014/10/None.png&#34;&gt;&lt;img src=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2014/10/None.png?resize=488%2C579&#34; alt=&#34;None&#34; width=&#34;488&#34; height=&#34;579&#34; class=&#34;alignnone size-full wp-image-978&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty arcpy: Compare Feature Class Table Schemas</title>
      <link>https://maprantala.com/2014/07/07/quick-dirty-arcpy-compare-feature-class-table-schemas/</link>
      <pubDate>Mon, 07 Jul 2014 05:06:18 -0500</pubDate>
      <guid>https://maprantala.com/2014/07/07/quick-dirty-arcpy-compare-feature-class-table-schemas/</guid>
      <description>&lt;p&gt;I&amp;rsquo;m in the process of rewriting a process, moving most of the processing from arcpy to postgresql-enabled python (love me some &lt;a href=&#34;http://initd.org/psycopg/&#34; target=&#34;_blank&#34;&gt;psycopg2&lt;/a&gt;).&lt;/p&gt;
&lt;p&gt;One of the QC checks I&amp;rsquo;m doing at the end of this re-write is just verifying that the feature class schemas are the same (or that the differences are intended)  under the new process as they were in the old process.&lt;/p&gt;
&lt;p&gt;And while ArcGIS does have a &lt;a href=&#34;http://resources.arcgis.com/en/help/main/10.1/index.html#//001700000007000000&#34; target=&#34;_blank&#34;&gt;good tool&lt;/a&gt; for this, there were a couple tweaks I wanted to make. Most notably, I wanted a list of fields that are not in both feature classes.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/07/TableCompare.png&#34; alt=&#34;ArcGIS Table Compare&#34;&gt;&lt;/p&gt;
&lt;p&gt;So I made a quick &amp;amp; dirty script to do that, nothing especially clever but I&amp;rsquo;ve found it useful. Download it from &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/ArcToolbox/ArcGIS_10_2/20140702_CompareTableFields&#34;&gt;GitHub&lt;/a&gt;. I have it currently set up to work on feature layers but you should be able to change the toolbox parameter types to allow feature classes or tables.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt;sys&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt;os

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printit&lt;/span&gt;(inMessage):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inMessage
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(inMessage)

featureclass1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
featureclass2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]

tableheaders &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;name, type, width, precision, domain&amp;#39;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;makeFieldDict&lt;/span&gt;(inFC):
    d &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Describe(inFC)
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dataset: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;baseName)
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Type: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataType)
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Path: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;catalogPath)
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)

    lFields&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(inFC)

    printit (tableheaders)
    fieldDict &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; dict()
    printit (lFields)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; lf &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; lFields:
        fieldDict[lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name,lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type,lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;length,lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;precision,lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain]
        printit (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;, &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;, &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;length)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;, &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;precision)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;, &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; fieldDict

fieldDict1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; makeFieldDict(featureclass1)
fieldDict2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; makeFieldDict(featureclass2)
errorList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Comparing Fields:&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iField &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; sorted(list(set(fieldDict1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;keys()&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;fieldDict2&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;keys()))):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (fieldDict1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;has_key(iField)):
        theResult &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; {0} not found in {1}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iField,featureclass1)
        errorList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(theResult)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;elif&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (fieldDict2&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;has_key(iField)):
        theResult &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; {0} not found in {1}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iField,featureclass2)
        errorList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(theResult)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (fieldDict1[iField] &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; fieldDict2[iField]):
            theResult &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; {0} OK&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iField)
        &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
            theResult &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; {0} Have Different Definitions &lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;   {1}: {2}&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\n&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;   {3}: {4}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iField,featureclass1,fieldDict1[iField],featureclass2,fieldDict2[iField])
            errorList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(theResult)

    printit( theResult )

printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; len(errorList) &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;:
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;GOOD! No difference Found!&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
    printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;These Differences Found:&amp;#34;&lt;/span&gt;)
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iError &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; errorList:
        printit(iError)

printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Done!&amp;#34;&lt;/span&gt;)

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Garmin GPX to Shapefile (SHP) conversion GPX2Shp.py</title>
      <link>https://maprantala.com/2014/05/16/garmin-gpx-to-shapefile-shp-conversion-gpx2shp.py/</link>
      <pubDate>Fri, 16 May 2014 21:11:20 -0500</pubDate>
      <guid>https://maprantala.com/2014/05/16/garmin-gpx-to-shapefile-shp-conversion-gpx2shp.py/</guid>
      <description>&lt;p&gt;I mentioned using &lt;a href=&#34;https://tapiriik.com&#34; target=&#34;_blank&#34;&gt;Tapiriik&lt;/a&gt; to batch download my entire Garmin Connect history–over 1,000 separate .GPX files. I found several tools to convert .&lt;a href=&#34;http://arcscripts.esri.com/details.asp?dbid=16797&#34; target=&#34;_blank&#34;&gt;GPX to shapefiles&lt;/a&gt; that worked but none seemed to recognize my heart rate data.&lt;/p&gt;
&lt;p&gt;The trick is Garmin extends the GPX specification to incorporate the heart rate:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;span style=&amp;quot;color: #333333;&amp;quot;&amp;gt;xmlns:gpxtpx=&amp;quot;http://www.garmin.com/xmlschemas/TrackPointExtension/v1&amp;quot;&amp;lt;/span&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Each track point looks like this:&lt;/p&gt;
&lt;div id=&#34;LC15&#34; class=&#34;line&#34;&gt;
       &lt;trkpt lat=&#39;43.68346489146352&amp;#8243; lon=&#39;-92.99583793468773&amp;#8243;&gt;
&lt;/div&gt;
&lt;div id=&#34;LC16&#34; class=&#34;line&#34;&gt;
          &lt;time&gt;2014-03-16T20:35:47+00:00&lt;/time&gt;
&lt;/div&gt;
&lt;div id=&#34;LC17&#34; class=&#34;line&#34;&gt;
          &lt;ele&gt;296.20001220703125
&lt;/div&gt;
&lt;div id=&#34;LC18&#34; class=&#34;line&#34;&gt;
          &lt;extensions&gt;
&lt;/div&gt;
&lt;div id=&#34;LC19&#34; class=&#34;line&#34;&gt;
            &lt;gpxtpx:TrackPointExtension&gt;
&lt;/div&gt;
&lt;div id=&#34;LC20&#34; class=&#34;line&#34;&gt;
              &lt;gpxtpx:hr&gt;86
&lt;/div&gt;
&lt;div id=&#34;LC21&#34; class=&#34;line&#34;&gt;
            &lt;!--&lt;span class=&#34;hiddenSpellError&#34; pre=&#34;&#34; data-mce-bogus=&#34;1&#34;--&gt;gpxtpx:TrackPointExtension&gt;
&lt;/div&gt;
&lt;div id=&#34;LC22&#34; class=&#34;line&#34;&gt;
          &lt;/extensions&gt;
&lt;/div&gt;
&lt;div id=&#34;LC23&#34; class=&#34;line&#34;&gt;
        &lt;!--&lt;span class=&#34;hiddenSpellError&#34; pre=&#34;&#34; data-mce-bogus=&#34;1&#34;--&gt;trkpt&gt;
&lt;/div&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Since the first few exiting GPX converters failed to meet my needs, I decided to make my own, at least partially.&lt;/p&gt;
&lt;p&gt;I used Joel Lawhead of &lt;a href=&#34;http://geospatialpython.com&#34; target=&#34;_blank&#34;&gt;GeospatialPython.com&lt;/a&gt;‘s &lt;a href=&#34;https://code.google.com/p/pyshp/&#34; target=&#34;_blank&#34;&gt;pyshp&lt;/a&gt; library to handle writing the shapefile. I added some basic loop and I stuck a template.prj in the workspace that gets copied once for each shapefile.&lt;/p&gt;
&lt;p&gt;Otherwise, nothing too fancy going on.  The code can be downloaded from &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/python/python/20140516_GPX2SHP&#34;&gt;Github&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import glob, os
import xml.etree.ElementTree as ET
import shapefile
import shutil

theNS = &amp;quot;{http://www.topografix.com/GPX/1/1}&amp;quot;.lower()
theNS2 = &amp;quot;{http://www.garmin.com/xmlschemas/TrackPointExtension/v1}&amp;quot;.lower()
templatePRJfile = &amp;quot;template.prj&amp;quot;

def elementIs(inElement,inTag):
    item1 = inTag.lower()
    item2 = elementName(inElement)
    return (inTag.lower() == elementName(inElement).lower())

def elementName(inElement):
    item1= inElement.tag.lower().replace(theNS,&amp;quot;&amp;quot;).replace(theNS2,&amp;quot;&amp;quot;)
    return item1

def convertTimeToSeconds(inTime):
    theSeconds = -1

    if (inTime.count(&amp;quot;:&amp;quot;)) == 2:
        try:
            inHour = inTime.split(&amp;quot;:&amp;quot;)[0]
            inMin = inTime.split(&amp;quot;:&amp;quot;)[1]
            inSec = inTime.split(&amp;quot;:&amp;quot;)[2]

            totalSec = float(inSec)
            totalSec += (float(inMin) * 60)
            totalSec += (float(inHour) * 3600)
            theSeconds = totalSec
        except:
            pass

    return theSeconds


def writeSHP(inSourceFile,inTrkList):
    w = shapefile.Writer(shapefile.POINT)
    w.field(&amp;quot;file&amp;quot;)
    w.field(&amp;quot;segment&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;vertex&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;datetime&amp;quot;,&amp;quot;C&amp;quot;,30)
    w.field(&amp;quot;date&amp;quot;,&amp;quot;C&amp;quot;,&amp;quot;10&amp;quot;,0)
    w.field(&amp;quot;time&amp;quot;,&amp;quot;C&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;sec&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;isec&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;totsec&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;elev&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;24&amp;quot;,14)
    w.field(&amp;quot;hr&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;8&amp;quot;,0)
    w.field(&amp;quot;last&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;1&amp;quot;,0)
    w.field(&amp;quot;lat&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;24&amp;quot;,16)
    w.field(&amp;quot;lon&amp;quot;,&amp;quot;N&amp;quot;,&amp;quot;24&amp;quot;,16)

    iTrkSegIndex = 0
    startSec =-1
    prevSec = -1
    for iTrkSeg in inTrkList:
        iTrkPtIndex = 0
        for iTrkPtDict in iTrkSeg:
            thisLine = &amp;quot;{0},{1},{2},*time*,*ele*,*hr*,*lat*,*lon*&amp;quot;.format(inSourceFile,iTrkSegIndex,iTrkPtIndex)

            theLat = None
            if (iTrkPtDict.has_key(&#39;lat&#39;)):
                try:
                    theLat = float(iTrkPtDict[&#39;lat&#39;])
                except:
                    pass

            theLon = None

            if (iTrkPtDict.has_key(&#39;lon&#39;)):
                try:
                    theLon = float(iTrkPtDict[&#39;lon&#39;])
                except:
                    pass

            theDate = None
            theTime = None
            theSeconds = -1
            segSeconds = -1
            totSeconds = -1

            if (iTrkPtDict.has_key(&#39;time&#39;)):
                theDateTime = iTrkPtDict[&#39;time&#39;]
                if (&amp;quot;T&amp;quot; in theDateTime):
                    theDate = theDateTime.split(&amp;quot;T&amp;quot;)[0]
                    theTimePlue = theDateTime.split(&amp;quot;T&amp;quot;)[1]
                    if (&amp;quot;+&amp;quot; in theTimePlue):
                        theTime = theTimePlue.split(&amp;quot;+&amp;quot;)[0]
                        theSeconds = convertTimeToSeconds(theTime)

                        if (prevSec &amp;lt; 0):
                            prevSec = theSeconds
                        if (startSec &amp;lt; 0):
                            startSec = theSeconds

                        segSeconds = theSeconds - prevSec
                        prevSec = theSeconds
                        totSeconds = theSeconds - startSec
            else:
                theDateTime = None

            if (iTrkPtDict.has_key(&#39;ele&#39;)):
                theElev = iTrkPtDict[&#39;ele&#39;]
            else:
                theElev = None

            if (iTrkPtDict.has_key(&#39;hr&#39;)):
                theHR = iTrkPtDict[&#39;hr&#39;]
            else:
                theHR = None

            if (iTrkPtIndex == len(iTrkSeg) - 1):
                theLast = 1
            else:
                theLast = 0

            w.point(theLon, theLat)
            try:
                                  w.record(inSourceFile.replace(&amp;quot;.gpx&amp;quot;,&amp;quot;&amp;quot;),iTrkSegIndex,iTrkPtIndex,theDateTime,theDate,theTime,theSeconds,segSeconds,totSeconds,theElev,theHR,theLast,theLat,theLon)

            except:
                print &amp;quot;############## ERROR ####################&amp;quot;
            iTrkPtIndex+=1

        iTrkSegIndex+=1


    w.save(inSourceFile.lower().replace(&amp;quot;.gpx&amp;quot;,&amp;quot;&amp;quot;))
    w = None
    if (os.path.exists(templatePRJfile)):
        newPRJFN = inSourceFile.lower().replace(&amp;quot;.gpx&amp;quot;,&amp;quot;.prj&amp;quot;)
        shutil.copyfile(templatePRJfile,newPRJFN)

def mainLoop():
    for iFile in glob.glob(&amp;quot;*.gpx&amp;quot;):
        print iFile
        tree = ET.parse(iFile)
        root=tree.getroot()

        theTrkList = []

        for iRoot in root:
            if elementIs(iRoot,&amp;quot;trk&amp;quot;): #&amp;quot;http://www.topografix.com/gpx/1/1}trk&amp;quot; in iRoot.tag.lower():
                for iTrkSeg in iRoot:
                    if not elementIs(iTrkSeg,&amp;quot;trkseg&amp;quot;):
                        continue
                    thisTrk = []

                    pntIndex = 0
                    for iTrkPt in iTrkSeg:
                        if not elementIs(iTrkPt,&amp;quot;trkpt&amp;quot;):
                            continue
                        trkPntDict = dict()
                        trkPntDict[&amp;quot;pntIndex&amp;quot;] = pntIndex
                        trkPntDict[&#39;lat&#39;] = iTrkPt.get(&#39;lat&#39;)
                        trkPntDict[&#39;lon&#39;] = iTrkPt.get(&#39;lon&#39;)

                        pntIndex+=1
                        for iElem in iTrkPt:
                            if elementIs(iElem,&amp;quot;extensions&amp;quot;):
                                for iSubElem in iElem:
                                    if (elementIs(iSubElem,&amp;quot;TrackPointExtension&amp;quot;)):
                                        for iExtensionElem in iSubElem:
                                            if elementIs(iExtensionElem,&amp;quot;hr&amp;quot;):
                                                trkPntDict[elementName(iExtensionElem)] = iExtensionElem.text
                            else:
                                trkPntDict[elementName(iElem)] = iElem.text

                        #print trkPntDict
                        thisTrk.append(trkPntDict)

                    theTrkList.append(thisTrk)
        writeSHP(iFile.lower(), theTrkList)


theLineList = mainLoop()

&lt;/code&gt;&lt;/pre&gt;&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Zipping a Shapefile from ArcCatalog</title>
      <link>https://maprantala.com/2014/05/06/zipping-a-shapefile-from-arccatalog/</link>
      <pubDate>Tue, 06 May 2014 05:42:04 -0500</pubDate>
      <guid>https://maprantala.com/2014/05/06/zipping-a-shapefile-from-arccatalog/</guid>
      <description>&lt;p&gt;Back in 2010, I posted a &lt;a href=&#34;https://maprantala.com/2010/12/10/zipping-a-shapefile-using-python/&#34; target=&#34;_blank&#34;&gt;python script &lt;/a&gt;and an &lt;a href=&#34;https://maprantala.com/2010/12/15/zipping-a-shapefile-via-arctoolbox/&#34; target=&#34;_blank&#34;&gt;ArcToolbox&lt;/a&gt; tool for zipping a shapefile.&lt;/p&gt;
&lt;p&gt;Well, I had a request to modify the code so it would not error out if it encounters a .lock file. While .lock files exist for a reason and shouldn&amp;rsquo;t be totally ignored, in some cases it is safe to do so, so I went ahead any modified the code, which can be downloaded from &lt;a href=&#34;https://github.com/MapRantala/Blog/tree/master/ArcToolbox/ArcGIS_9.3/20101215_ZipShapefileFromArcToolbox&#34; target=&#34;_blank&#34;&gt;Github&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The guts of the code is here, though:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import zipfile
import sys
import os
import glob

theShapeFile = sys.argv[1]
outputZipFile = sys.argv[2]
skipLockFile = sys.argv[3]

def zipShapefile(inShapefile, newZipFN, skipLockFile):
    print &#39;Starting to Zip &#39;+inShapefile+&#39; to &#39;+newZipFN

    if not (os.path.exists(inShapefile)):
        print inShapefile + &#39; Does Not Exist&#39;
        return False

    if (os.path.exists(newZipFN)):
        print &#39;Deleting &#39;+newZipFN
        os.remove(newZipFN)

        if (os.path.exists(newZipFN)):
            print &#39;Unable to Delete&#39;+newZipFN
            return False

    zipobj = zipfile.ZipFile(newZipFN,&#39;w&#39;)

    for infile in glob.glob( inShapefile.lower().replace(&amp;quot;.shp&amp;quot;,&amp;quot;.*&amp;quot;)):
        print infile
        if not ((os.path.splitext(infile.lower())[1] == &amp;quot;.lock&amp;quot;) and (skipLockFile.lower() == &amp;quot;true&amp;quot;)):
            zipobj.write(infile,os.path.basename(infile),zipfile.ZIP_DEFLATED)

    zipobj.close()

    return True

zipShapefile(theShapeFile,outputZipFile,skipLockFile)
print &amp;quot;done!&amp;quot;

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Friday Fave: Geodatabase Geek</title>
      <link>https://maprantala.com/2014/05/02/friday-fave-geodatabase-geek/</link>
      <pubDate>Fri, 02 May 2014 05:02:12 -0500</pubDate>
      <guid>https://maprantala.com/2014/05/02/friday-fave-geodatabase-geek/</guid>
      <description>&lt;p&gt;This &lt;a href=&#34;https://maprantala.com/category/friday-fave/&#34;&gt;Friday Fave&lt;/a&gt; is more for utility than pleasure.&lt;/p&gt;
&lt;p&gt;Unfortunately, I have been working to determine why my views and query layers perform so much worse than directly accessing my feature class.&lt;/p&gt;
&lt;p&gt;My Googling led me to &lt;a href=&#34;http://gdbgeek.wordpress.com/&#34; target=&#34;_blank&#34;&gt;Geodatabase Geek&lt;/a&gt;, by Trevor Hart, &lt;a href=&#34;http://www.eagle.co.nz/&#34; target=&#34;_blank&#34;&gt;Eagle Technology Group Ltd&lt;/a&gt;.  Trevor has some real good information about Geodatabases and also  gave a good lightening talk on &lt;a href=&#34;http://video.esri.com/watch/2481/usage-reporting-on-arcgis-101-for-server&#34;&gt;Usage Reporting on ArcGIS 10.1 for Server &lt;/a&gt;at the 2013 ESRI International Developer&amp;rsquo;s Conference.&lt;/p&gt;
&lt;p&gt;One tool he pointed out was &lt;a href=&#34;https://www.arcgis.com/home/item.html?id=a269d03aa1c840638680e2902dadecac&#34; target=&#34;_blank&#34;&gt;Mxdperfstat&lt;/a&gt; for benchmarking the performance of your MXD. Trevor used it to compare the performance of a &lt;a href=&#34;http://gdbgeek.wordpress.com/2014/01/15/feature-class-vs-query-layer-vs-spatial-view/&#34; target=&#34;_blank&#34;&gt;Feature Class vs Query Layer vs Spatial View&lt;/a&gt;. While the official version is available for ArcGIS 9.3 through 10.2, I do want to point out &lt;a href=&#34;http://www.husseinnasser.com/2013/04/mxdperfstat-101-download-mxd.html&#34; target=&#34;_blank&#34;&gt;Hussein Nasser&amp;rsquo;s 10.1 version&lt;/a&gt; which he put out before the official 10.1 version came out (it&amp;rsquo;s not really a version, more of a work-around but I like his ingenuity).&lt;/p&gt;
&lt;p&gt;My results were significantly different on our 10.0 database server, the spatial view I was testing was much slower.  The query for both the spatial view and query layer was simply &amp;lsquo;Select * from &lt;em&gt;featureclass&lt;/em&gt;&amp;rsquo;&lt;/p&gt;
&lt;p&gt;So not sure what to make of the performance yet, I&amp;rsquo;ve got a spatial index made so not sure what else I can try.&lt;figure id=&#34;attachment_936&#34; aria-describedby=&#34;caption-attachment-936&#34; style=&#34;width: 597px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/05/MGSDB1.png&#34; alt=&#34;ArcSDE 10.0 Performance&#34;&gt;&lt;figcaption id=&#34;caption-attachment-936&#34; class=&#34;wp-caption-text&#34;&gt;ArcSDE 10.0 Performance&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Friday Fave: Tapiriik</title>
      <link>https://maprantala.com/2014/04/25/friday-fave-tapiriik/</link>
      <pubDate>Fri, 25 Apr 2014 05:55:13 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/25/friday-fave-tapiriik/</guid>
      <description>&lt;p&gt;This &lt;a href=&#34;https://maprantala.com/category/fun-maps/friday-fave/&#34;&gt;Friday Fave&lt;/a&gt; is a little bit different.&lt;/p&gt;
&lt;p&gt;My interest in geospatial technologies (although we just called it GIS back then) largely because I wanted to measure my running routes more accurately and efficiently than the paper map &amp;amp; scrap of paper method I was using in the early 90s. When I was introduced to GIS, I knew what I was going to use it for.&lt;/p&gt;
&lt;p&gt;Now that GPS technology is ubiquitous–I&amp;rsquo;m currently using four different GPS devices, at the same time, on my bike rides–I seldom have to use a map to measure my routes. I may still use &lt;a href=&#34;http://www.mapmyrun.com&#34; target=&#34;_blank&#34;&gt;MapMyRun.com&lt;/a&gt; to plan a route ahead of time if I&amp;rsquo;m running in a new area or trying to plan a loop of a certain distance but GPS has really made it so simple to just go out and run.&lt;/p&gt;
&lt;p&gt;While there are several GPS options available, I have used Garmin ever since their 405 Forerunner came out. This was their first watch that didn&amp;rsquo;t get confused for a Timex-Sinclair 1000 strapped to your wrist.&lt;figure id=&#34;attachment_928&#34; aria-describedby=&#34;caption-attachment-928&#34; style=&#34;width: 300px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/Zx81-timex-manipulated2.jpg&#34; alt=&#34;Timex Sinclair 1000&#34;&gt;&lt;figcaption id=&#34;caption-attachment-928&#34; class=&#34;wp-caption-text&#34;&gt;Timex Sinclair 1000&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;Garmin&amp;rsquo;s watches upload their data to &lt;a href=&#34;https://tapiriik.com/&#34; target=&#34;_blank&#34;&gt;Gamin Connect,&lt;/a&gt; which works fine, but for a project I recently started, I wanted to down load all my data which Garmin Connect does not make easy. I had over 1,000 data logs and downloading them individually was not going to happen.&lt;/p&gt;
&lt;p&gt;A little Googling led me to &lt;a href=&#34;https://tapiriik.com/&#34; target=&#34;_blank&#34;&gt;tapiriik.com&lt;/a&gt;, which allows you to share data amongst several different online services that endurance athletes might use including Runkeeper, Strava, Garmin Connect, SportTracks, DropBox.com, and Training Peaks.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/Screen-Shot-2014-04-24-at-9.52.48-PM.png&#34; alt=&#34;https://tapiriik.com/&#34;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;You can use Tapiriik for free (you just need to visit their website to start synchronization) or for $2 per year they will automatically synchronize data between your accounts. You just provide your account information for whichever sites you want to synchronize and either visit their site or pay $2 and it will automatically share data between your accounts.&lt;/p&gt;
&lt;p&gt;I linked to my Garmin Connect and Dropbox accounts and tapiriik and after some chugging, I had .GPX files for all of my data.&lt;/p&gt;
&lt;p&gt;It was easy and didn&amp;rsquo;t take very long. Definitely met my needs–I haven&amp;rsquo;t shared data between other services but I do use the desktop version of SportTracks and considered using their web version of the software but didn&amp;rsquo;t know how I would upload all my data.  Now I know.&lt;/p&gt;
&lt;p&gt;This product definitely saved me a bunch of time. The one thing I wonder, though, is what does &amp;lsquo;Tapiriik&amp;rsquo; means?&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty arcpy: Bulk Changing Field Values</title>
      <link>https://maprantala.com/2014/04/23/quick-dirty-arcpy-bulk-changing-field-values/</link>
      <pubDate>Wed, 23 Apr 2014 05:18:24 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/23/quick-dirty-arcpy-bulk-changing-field-values/</guid>
      <description>&lt;p&gt;In mapping cross sections, our geologists often find themselves renaming their stratigraphic units midway, or at the end, of creating multiple cross sections.  This can cause a situation where we need to change multiple values in multiple fields in multiple feature classes–a situation that can get messy very fast.&lt;/p&gt;
&lt;p&gt;Perfect situation for a quick &amp;amp; dirty arcpy script and, in this case, an &lt;a href=&#34;https://github.com/MapRantala/Blog&#34;&gt;ArcToolbox tool that can be downloaded&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;This tool will change all feature classes in the O:\clay_cga\sand-distribution_model\dnrPackages\stratlines directory.&lt;/p&gt;
&lt;p&gt;It will look at two fields, [strat] and [unit] and make these changes:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&amp;lsquo;go&amp;rsquo; becomes &amp;lsquo;gro&amp;rsquo;&lt;/li&gt;
&lt;li&gt;&amp;lsquo;goc&amp;rsquo; becomes &amp;lsquo;grc&amp;rsquo;&lt;/li&gt;
&lt;li&gt;&amp;lsquo;sgb&amp;rsquo; becomes &amp;lsquo;grb&amp;rsquo;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;And since I have Case Sensitive checked, &amp;lsquo;Go&amp;rsquo; will not get changed to &amp;lsquo;gro&amp;rsquo;.  Also note that only full values that match values in the Old Value List get changed, part matches are left as-is so &amp;lsquo;got&amp;rsquo; would be left as-is even though the first two characters match &amp;lsquo;go&amp;rsquo;.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/BulkFieldChange.png&#34; alt=&#34;Bulk Field Change&#34;&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import arcpy
import sys, string, arcgisscripting
import arcpy

def printit(inString):
    print inString
    arcpy.AddMessage(inString)

def printerr(inString):
    print inString
    arcpy.AddError(inString)

def fieldExists(tablename,indexname):

 if not arcpy.Exists(tablename):
  return False

 tabledescription = arcpy.Describe(tablename)

 for iField in tabledescription.fields:
     if (iField.Name.lower() == indexname.lower()):
         return True

 return False


if len(sys.argv) &amp;gt; 1:
    inDirectory = sys.argv[1]
    inFieldNameRaw = sys.argv[2]
    oldValue = sys.argv[3].replace(&amp;quot;,&amp;quot;,&amp;quot; &amp;quot;)
    newValue = sys.argv[4].replace(&amp;quot;,&amp;quot;,&amp;quot; &amp;quot;)
    caseSensitiveRaw = sys.argv[5]
else:
    inDirectory = r&amp;quot;C:\temp\test\stratest&amp;quot;
    inFieldNameRaw = &amp;quot;strat&amp;quot;
    oldValue = &amp;quot;go, goc, sgb&amp;quot;.replace(&amp;quot;,&amp;quot;,&amp;quot; &amp;quot;)
    newValue = &amp;quot;gro grc grb&amp;quot;.replace(&amp;quot;,&amp;quot;,&amp;quot; &amp;quot;)
    caseSensitiveRaw = &amp;quot;true&amp;quot;

caseSensitive = (caseSensitiveRaw.lower() == &amp;quot;true&amp;quot;)
fieldNameList = inFieldNameRaw.replace(&amp;quot;,&amp;quot;,&amp;quot; &amp;quot;).split()

printit(&amp;quot;Starting&amp;quot;)
printit(&amp;quot; Workspace: &amp;quot;+str(inDirectory))
printit( &amp;quot; inFieldName: &amp;quot;+str(inFieldNameRaw))
printit( &amp;quot; oldValue: &amp;quot;+str(oldValue))
printit( &amp;quot; newValue: &amp;quot;+str(newValue))
printit( &amp;quot; caseSensitive: &amp;quot;+str(caseSensitive))

valueDict = dict()

def initialQC():
    global valueDict

    if not (arcpy.Exists(inDirectory)):
        printerr(&amp;quot;Workspace {0} does not exist&amp;quot;.format(inDirectory))
        return False

    if (len(oldValue.split()) &amp;lt;&amp;gt; len(newValue.split())):
        printerr(&amp;quot;Number of values in {0} does not equal number of values in {1}&amp;quot;.format(oldValue,newValue))
        return False

    iValueIndex = 0
    for iOldValue in oldValue.split():
        if (caseSensitive):
            thisKey = iOldValue
        else:
            thisKey = iOldValue.lower()

        if (valueDict.has_key(thisKey)):
            printerr(&amp;quot;ERROR: Value, {0}, is repeated, cancelling...&amp;quot;.format(thisKey))
            return False

        valueDict[thisKey] = newValue.split()[iValueIndex]
        iValueIndex+=1
    return True

def makeFieldList(inFC):
    thisFieldList = []

    for iField in fieldNameList:
        if (fieldExists(inFC,iField)):
            thisFieldList.append(iField)

    return thisFieldList


def main():
    arcpy.env.workspace = inDirectory
    printit(valueDict)
    for iFC in arcpy.ListFeatureClasses():
        printit(&amp;quot;Working on {0}&amp;quot;.format(iFC))

        iFieldList = makeFieldList(iFC)
        if (len(iFieldList) == 0):
            printit(&amp;quot; No fields to change, Skipping...&amp;quot;)
            continue

        rows = arcpy.UpdateCursor(iFC)

        changes = 0
        printit(&amp;quot; Changing Rows&amp;quot;)
        for row in rows:
            iChange = 0
            for iField in iFieldList:
                iValue = str(row.getValue(iField))
                newValue = iValue

                if valueDict.has_key(iValue):
                    newValue = valueDict[iValue]
                else:
                    if not (caseSensitive):
                        if valueDict.has_key(iValue.lower()):
                            newValue = valueDict[iValue.lower()]

                if (newValue &amp;lt;&amp;gt; iValue):
                    printit(&amp;quot;CHANGE {0}&amp;quot;.format(newValue))
                    row.setValue(iField,newValue)
                    iChange+=1

            if (iChange &amp;gt; 0):
                changes+=1
                rows.updateRow(row)
        printit(&amp;quot; Made {0} changes&amp;quot;.format(changes))
        del row
        del rows

    printit(&amp;quot;Main&amp;quot;)

if (initialQC()==True):
    main()

printit(&amp;quot;Done&amp;quot;)

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Friday Fave: Custom Maps App for Android</title>
      <link>https://maprantala.com/2014/04/18/friday-fave-custom-maps-app-for-android/</link>
      <pubDate>Fri, 18 Apr 2014 06:11:58 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/18/friday-fave-custom-maps-app-for-android/</guid>
      <description>&lt;p&gt;I admit, I love picking up freebie maps. Whether it is from the front desk of a hotel or from the bicycle shop, there is a certain appeal to seeing what people put on maps. I have maps organic orchards, breweries, &lt;a href=&#34;http://thefriends.org/wp-content/uploads/2012/12/mn_writers_on_the_map_web_download.pdf&#34; target=&#34;_blank&#34;&gt;Minnesota authors&lt;/a&gt;, rails to trails, zoos, fictional places, race maps, and a variety of other things that someone felt the need to cartographize.&lt;figure id=&#34;attachment_896&#34; aria-describedby=&#34;caption-attachment-896&#34; style=&#34;width: 198px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/Screen-Shot-2014-04-10-at-10.35.26-PM-198x300.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;(&lt;a href=&#34;http://thefriends.org/wp-content/uploads/2012/12/mn_writers_on_the_map_web_download.pdf&#34;&gt;http://thefriends.org/wp-content/uploads/2012/12/mn_writers_on_the_map_web_download.pdf&lt;/a&gt;)&lt;figcaption id=&#34;caption-attachment-896&#34; class=&#34;wp-caption-text&#34;&gt;&lt;a href=&#34;http://thefriends.org/&#34;&gt;http://thefriends.org/&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;So, with all these paper maps lying around, I was thrilled to find &lt;a href=&#34;http://www.custommapsapp.com&#34; target=&#34;_blank&#34;&gt;Custom &lt;span style=&#34;line-height: 1.5;&#34;&gt;Maps&lt;/span&gt;&lt;/a&gt;&lt;span style=&#34;line-height: 1.5;&#34;&gt;, a free app on&lt;/span&gt;&lt;span style=&#34;line-height: 1.5;&#34;&gt; &lt;/span&gt;
&lt;a style=&#34;line-height: 1.5; color: #41a62a; outline: #000000;&#34; href=&#34;https://play.google.com/store/apps/details?id=com.custommapsapp.android&#34; target=&#34;_blank&#34;&gt;Google Play&lt;/a&gt;&lt;span style=&#34;line-height: 1.5;&#34;&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;This app allows you to take a picture (or use an image on your device) and georeference it.  You can then view your location on the map. I&amp;rsquo;ve tried it with a few maps and have been happy with the results.&lt;/p&gt;
&lt;p&gt;Similar to georeferencing in a desktop application, you select points on the map and then the same points on a control. You need at lest two or three points. After doing it a couple of times, the process becomes pretty easy and it just takes a minute or two from taking the picture to viewing your current location on the map.&lt;figure id=&#34;attachment_900&#34; aria-describedby=&#34;caption-attachment-900&#34; style=&#34;width: 180px&#34; class=&#34;wp-caption aligncenter&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/CustomMaps-AlignPoint.png&#34; alt=&#34;http://www.custommapsapp.com&#34;&gt;&lt;figcaption id=&#34;caption-attachment-900&#34; class=&#34;wp-caption-text&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.custommapsapp.com&#34;&gt;http://www.custommapsapp.com&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;An example use case scenario for this app is you are lugging your family around at an overwhelming large amusement park and never quite sure where you are. You can take a picture of the map you picked up at the entrance, georeference it, and your phone will then show exactly where you are on that map and where the nearest loo is.&lt;/p&gt;
&lt;p&gt;The biggest limitation I&amp;rsquo;ve seen so far is that there is a limit of 3-5 megapixel size limit on the image. Apparently this is an android limitation on how much memory an app can consume. But if you adjust your camera settings not to exceed this, you should be good.&lt;/p&gt;
&lt;p&gt;So far, I&amp;rsquo;m enjoying this app. The author, Marko Teittinen (a good Finn name), has made the source code &lt;a href=&#34;https://code.google.com/p/custom-maps/&#34;&gt;open source&lt;/a&gt; so I look forward to digging into it in more detail.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Friday Fave: Cartozia Tales</title>
      <link>https://maprantala.com/2014/04/11/friday-fave-cartozia-tales/</link>
      <pubDate>Fri, 11 Apr 2014 06:15:02 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/11/friday-fave-cartozia-tales/</guid>
      <description>&lt;p&gt;Obviously Cartographers belong in the same category as other superheroes like Superman, Batman, and Spiderman and we finally have a our own comic book to prove it.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://cartozia.com&#34; target=&#34;_blank&#34;&gt;&lt;em&gt;Cartozia Tales&lt;/em&gt;&lt;/a&gt; is a collaborative effort of nine indy artists with two guest artist each issue.&lt;/p&gt;
&lt;p&gt;They have an interesting plan, they&amp;rsquo;ve split the world into nine regions (what&amp;rsquo;s the name for the ninth of an area, nona-rant?) and the artist will tell a story from a different region each issue. They may build off the region&amp;rsquo;s story from the previous issue, continue on the story they told the previous issue, and start something fresh.&lt;/p&gt;
&lt;p&gt;After being funded by a &lt;a href=&#34;https://www.kickstarter.com/projects/1765342446/cartozia-tales-ten-issues?ref=live&#34; target=&#34;_blank&#34;&gt;KickStarter campaign&lt;/a&gt;, they&amp;rsquo;ve shipped three issues already and have at least seven more promised. Think the project definitely deserve&amp;rsquo;s a look.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Friday Fave: Public Workout Maps</title>
      <link>https://maprantala.com/2014/04/05/friday-fave-public-workout-maps/</link>
      <pubDate>Sat, 05 Apr 2014 05:15:31 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/05/friday-fave-public-workout-maps/</guid>
      <description>&lt;p&gt;When I first found out about GIS, the first application that came to mind was using it to map my running routes. At that time, I was using paper maps and scraps of paper to measure how far I was running each day. GIS obviously offered a better method.&lt;/p&gt;
&lt;p&gt;Almost twenty years later, GPS has become so common place that I think we have four or five devices in our household that have GPS capabilities and measuring my runs has become ridiculously simple.&lt;/p&gt;
&lt;p&gt;Given that background, you can understand why I love projects like &lt;a href=&#34;http://barsukov.net/endomondo.html&#34; target=&#34;_blank&#34;&gt;this project&lt;/a&gt; by Nikita Barsukov, who compiled publicly available data from &lt;a href=&#34;http://www.endomondo.com&#34; target=&#34;_blank&#34;&gt;Endomondo&lt;/a&gt; and created maps of public running workout tracks for a variety of European Cities, including this sample from Helsinki.&lt;figure id=&#34;attachment_874&#34; aria-describedby=&#34;caption-attachment-874&#34; style=&#34;width: 300px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/helsinki.png&#34; alt=&#34;helsinki&#34;&gt;&lt;/p&gt;
&lt;figcaption id=&#34;caption-attachment-874&#34; class=&#34;wp-caption-text&#34;&gt;&lt;a href=&#34;http://barsukov.net/endomondo.html&#34; target=&#34;_blank&#34;&gt;Barsukov.Net&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt; 
&lt;p&gt;Flowing Data, using a similar concept, generated &lt;a href=&#34;http://flowingdata.com/2014/02/05/where-people-run/&#34; target=&#34;_blank&#34;&gt;similar maps&lt;/a&gt; for several cities in the United States, including &lt;a href=&#34;http://flowingdata.com/2014/02/05/where-people-run/#jp-carousel-33732&#34; target=&#34;_blank&#34;&gt;Minneapolis&lt;/a&gt;–some areas I know.&lt;figure id=&#34;attachment_877&#34; aria-describedby=&#34;caption-attachment-877&#34; style=&#34;width: 214px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://flowingdata.com/2014/02/05/where-people-run/#jp-carousel-33732&#34; target=&#34;_blank&#34;&gt;&lt;img class=&#34;size-medium wp-image-877 &#34; alt=&#34;http://flowingdata.com/2014/02/05/where-people-run/#jp-carousel-33732&#34; src=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2014/04/Screen-Shot-2014-04-03-at-7.57.30-PM-214x300.png?resize=214%2C300&#34; width=&#34;214&#34; height=&#34;300&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;figcaption id=&#34;caption-attachment-877&#34; class=&#34;wp-caption-text&#34;&gt;&lt;a href=&#34;http://flowingdata.com/2014/02/05/where-people-run/&#34; target=&#34;_blank&#34;&gt;&lt;a href=&#34;http://flowingdata.com/2014/02/05/where-people-run/&#34;&gt;http://flowingdata.com/2014/02/05/where-people-run/&lt;/a&gt;&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve got about six years of running data of my own that I should use to generate a personal running route map but would be a fun project.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>arcpy.ListFeatureClasses() Bug</title>
      <link>https://maprantala.com/2014/04/02/arcpy.listfeatureclasses-bug/</link>
      <pubDate>Wed, 02 Apr 2014 18:59:06 -0500</pubDate>
      <guid>https://maprantala.com/2014/04/02/arcpy.listfeatureclasses-bug/</guid>
      <description>&lt;p&gt;I was recently re-evaluating our back-up procedures and discovered and found a nasty bug with the arcpy&amp;rsquo;s &lt;a href=&#34;http://resources.arcgis.com/en/help/main/10.2/index.html#//018v00000018000000&#34; target=&#34;_blank&#34;&gt;ListFeatureClasses&lt;/a&gt; request. If you have a feature class in a feature dataset with the same name, ListFeatureClasses may not find it or anything else in that feature dataset.&lt;/p&gt;
&lt;p&gt;Unfortunately, we recently made our daily backup a python-based system that uses ListFeatureClasses and got bit by this bug.&lt;/p&gt;
&lt;p&gt;After discovering missing data in our backups, I reconstructed what happened and found this bug. Below is arcpy code that iterates through the feature datasets in a geodatabase and lists the feature classes:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;copyAll&lt;/span&gt;():
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFeatureClass &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFeatureClasses():
        &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; Feature Class: {0}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iFeatureClass))
    iFeatureClassFull &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; None

testGDBname &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;mgs_sandbox.sde&amp;#34;&lt;/span&gt;
arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;env&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;workspace &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; testGDBname

copyAll()
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFD &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListDatasets(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Feature&amp;#34;&lt;/span&gt;):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Feature Dataset {0}:&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(iFD))
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;env&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;workspace &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; testGDBname&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(iFD)
    copyAll()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And here is a screen shot of the contents of a test enterprise geodatabase, you&amp;rsquo;ll see it has a feature data set named &amp;lsquo;outcrops&amp;rsquo; that has a feature class also named &amp;lsquo;outcrops&amp;rsquo; within it:&lt;br&gt;
&lt;img src=&#34;https://maprantala.com/images/2014/04/sandbox.png&#34; alt=&#34;sandbox&#34;&gt;&lt;/p&gt;
&lt;p&gt;And the results list only the feature dataset:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/results.png&#34; alt=&#34;results&#34;&gt;&lt;/p&gt;
&lt;p&gt;But if I rename the feature dataset (e.g. outcrop_fd), the results are what I would hope for:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/04/results2.png&#34; alt=&#34;results&#34;&gt;&lt;/p&gt;
&lt;p&gt;I found that the feature class does not even need to be within the feature dataset and also the problem does not always occur, I have had the code successfully run in some cases.&lt;/p&gt;
&lt;p&gt;Once I confirmed the problem, I did find &lt;a href=&#34;http://forums.arcgis.com/threads/31291-List-feature-classes-in-a-geodatabase-using-Python&#34; target=&#34;_blank&#34;&gt;this thread&lt;/a&gt; from almost three years ago that mentions the bug. One poster indicated the same thing occurs in ArcObjects which leads me to think something may not be getting registered right in the sde tables.&lt;/p&gt;
&lt;p&gt;I was not able to re-create this using either personal or file geodatabases.&lt;/p&gt;
&lt;p&gt;So I adopting the policy of not using the same name for a feature dataset as for a feature class.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Calculating Running Total with arcpy</title>
      <link>https://maprantala.com/2014/02/13/arcmap-field-calculator-calculating-running-total-with-arcpy/</link>
      <pubDate>Thu, 13 Feb 2014 06:06:37 -0600</pubDate>
      <guid>https://maprantala.com/2014/02/13/arcmap-field-calculator-calculating-running-total-with-arcpy/</guid>
      <description>&lt;p&gt;I had a user with a series of GPS points (that were in chronological order) that they wanted to know the accumulated distance from the start to each point in their shapefile. First, we calculated the distance from each point to the previous point into a field called [DistFt].&lt;/p&gt;
&lt;p&gt;Then, we hacked out this quick python function to accumulate the total distance in Arcmap&amp;rsquo;s Field Calculator:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;totalDistance &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;accumulateDistance&lt;/span&gt;(inDist):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;global&lt;/span&gt; totalDistance
   totalDistance &lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt; inDist
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; totalDistance
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And we called it:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;accumulateDistance(&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;DistFt&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2014/02/accumulatedist.png&#34; alt=&#34;accumulateDist&#34;&gt;&lt;/p&gt;
&lt;p&gt;And we got what we wanted.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Maximum Legend Items from a ArcGIS Server service</title>
      <link>https://maprantala.com/2014/02/11/arcmap-maximum-legend-items-from-a-arcgis-server-service/</link>
      <pubDate>Tue, 11 Feb 2014 06:02:42 -0600</pubDate>
      <guid>https://maprantala.com/2014/02/11/arcmap-maximum-legend-items-from-a-arcgis-server-service/</guid>
      <description>&lt;p&gt;Recently we took a call from a user who could not see the legend for one of the feature classes in one of our services. (Precambrian Bedrock in &lt;a href=&#34;http://mgsweb2.mngs.umn.edu/arcgis/services/state/mnbdrkgeology&#34;&gt;http://mgsweb2.mngs.umn.edu/arcgis/services/state/mnbdrkgeology&lt;/a&gt; )&lt;/p&gt;
&lt;p&gt;After trying some standard things–restarting the service, checking the source .MXD–I turned to The Google Machine and quickly found help from ESRI: &lt;a href=&#34;http://support.esri.com/zh-cn/knowledgebase/techarticles/detail/33741&#34;&gt;http://support.esri.com/zh-cn/knowledgebase/techarticles/detail/33741&lt;/a&gt; .&lt;/p&gt;
&lt;p&gt;Turns out the default number of legend items ArcMap will display from an ArcGIS Server map service layer is 100 and we had 102 in the problematic layer. (I plead innocence, blame the geologist for needing that many categories).&lt;/p&gt;
&lt;p&gt;The solution was to edit the Windows registry and change the setting for &amp;lsquo;Maximum Legend Count&amp;rsquo; from 100 to something higher than 102. After doing that (see path note below) and restarting ArcMap, the legend showed for us.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Path Details&lt;/strong&gt;&lt;br&gt;
The path turned out to be a little different on Windows 7 than the paths indicated in the help article.&lt;br&gt;
ESRI indicated that the path varied by ArcGIS version:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;ArcGIS 9.3.x: HKEY_CURRENT_USER &amp;gt; Software &amp;gt; ESRI &amp;gt; MapServerLayer&lt;/li&gt;
&lt;li&gt;ArcGIS 10.0: HKEY_CURRENT_USER &amp;gt; Software &amp;gt; ESRI &amp;gt; Desktop10.0 &amp;gt; ArcMap &amp;gt; Server &amp;gt; MapServerLayer&lt;/li&gt;
&lt;li&gt;ArcGIS 10.1: HKEY_CURRENT_USER &amp;gt; Software &amp;gt; ESRI &amp;gt; Desktop10.1 &amp;gt; ArcMap &amp;gt; Server &amp;gt; MapServerLayer&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I actually changed this in a number of locations–presumably once for each user profile on my machine. Each followed a pattern something like:&lt;/p&gt;
&lt;p&gt;HKEY_USERSS-1-5-23412341234-123412342134-12341234123-1302SoftwareESRIArcMapServerMapServerLayer&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Extra Information&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Out of cursiousity, I wondered if the 100 item limit was a per &lt;strong&gt;service&lt;/strong&gt; or per &lt;strong&gt;layer&lt;/strong&gt; limitation so I set my limit at 103. Because the service has several other layers, the total number of layers in the legend was about 130. Everything drew OK so it appears the limit applies per layer.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Arcpy: Check if a field exists</title>
      <link>https://maprantala.com/2013/09/23/arcpy-check-if-a-field-exists/</link>
      <pubDate>Mon, 23 Sep 2013 06:47:36 -0500</pubDate>
      <guid>https://maprantala.com/2013/09/23/arcpy-check-if-a-field-exists/</guid>
      <description>&lt;p&gt;I was helping a co-worker who needed to check if a field exists in their arcpy script. Since we were located at their computer, I thought I would just do a quick Google search and pull the code off this blog. Seemed logical since I the original purpose was exactly that—to serve as a handy, public place to store code snippets that I use &amp;amp; that others might find handy.&lt;/p&gt;
&lt;p&gt;Anyhow, my Google Search on “&lt;a href=&#34;https://www.google.com/#q=Node+Dangles+field+Exists&#34;&gt;Node Dangles field Exists&lt;/a&gt;” came up with a &lt;a href=&#34;https://maprantala.com/2011/01/27/checking-to-see-if-a-field-index-exists-using-python/&#34;&gt;9.3 script&lt;/a&gt; to check if field index exists. And I also have a &lt;a href=&#34;https://maprantala.com/2011/02/21/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10-0/&#34;&gt;10.0 version&lt;/a&gt; but did not come up with the field exists snippet. So here it is:&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2013/09/image2.png&#34;&gt;&lt;img style=&#34;background-image: none; padding-top: 0; padding-left: 0; display: inline; padding-right: 0; border: 0;&#34; title=&#34;image&#34; alt=&#34;image&#34; src=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2013/09/image_thumb2.png?resize=445%2C131&#34; width=&#34;445&#34; height=&#34;131&#34; border=&#34;0&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;def fieldExists(inFeatureClass, inFieldName):
   fieldList = arcpy.ListFields(inFeatureClass)
   for iField in fieldList:
      if iField.name.lower() == inFieldName.lower():
         return True
   return False

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Number of parts in multi-part feature</title>
      <link>https://maprantala.com/2013/09/05/arcmap-field-calculator-number-of-parts-in-multi-part-feature/</link>
      <pubDate>Thu, 05 Sep 2013 14:04:40 -0500</pubDate>
      <guid>https://maprantala.com/2013/09/05/arcmap-field-calculator-number-of-parts-in-multi-part-feature/</guid>
      <description>&lt;p&gt;In the last week, I have looked for multi-part features a couple of times. Today, I was looking for multi-part polygons after dealing with the fall-out of a case of Clip Gone Wild as shown below.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2013/09/image.png&#34;&gt;&lt;img style=&#34;background-image:none;padding-top:0;padding-left:0;display:inline;padding-right:0;border:0;&#34; title=&#34;image&#34; alt=&#34;image&#34; src=&#34;https://i1.wp.com/maprantala.com/wp-content/uploads/2013/09/image_thumb.png?resize=554%2C416&#34; width=&#34;554&#34; height=&#34;416&#34; border=&#34;0&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I have not found a way to write a query to find these but Field Calculator does allow you to calculate a field’s value to the number of parts.&lt;/p&gt;
&lt;p&gt;Using the Python parser, just write the formula (note that case matters): !shape!.partCount&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://i2.wp.com/maprantala.com/wp-content/uploads/2013/09/image1.png&#34;&gt;&lt;img style=&#34;background-image:none;padding-top:0;padding-left:0;display:inline;padding-right:0;border:0;&#34; title=&#34;image&#34; alt=&#34;image&#34; src=&#34;https://i1.wp.com/maprantala.com/wp-content/uploads/2013/09/image_thumb1.png?resize=633%2C483&#34; width=&#34;633&#34; height=&#34;483&#34; border=&#34;0&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcSDE Tip: Finding an ArcSDE instance&#39;s port</title>
      <link>https://maprantala.com/2013/02/26/arcsde-tip-finding-an-arcsde-instances-port/</link>
      <pubDate>Tue, 26 Feb 2013 05:25:03 -0600</pubDate>
      <guid>https://maprantala.com/2013/02/26/arcsde-tip-finding-an-arcsde-instances-port/</guid>
      <description>&lt;p&gt;One of my main tasks right now is to document many of the details of maintaining ArcSDE geodatabases so I anticipate having several blog posts on this topic that are re-writes of documents I am working on. I am presuming that the person will have no ArcSDE experience so I am documenting very detailed information.&lt;/p&gt;
&lt;p&gt;Almost all of the ArcSDE commands require that you specify which instance (service/port) the command applies to by using the &amp;lsquo;-i&amp;rsquo; parameter.&lt;figure id=&#34;attachment_755&#34; aria-describedby=&#34;caption-attachment-755&#34; style=&#34;width: 672px&#34; class=&#34;wp-caption aligncenter&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2013/02/instanceparameter1.png&#34; alt=&#34;ArcSDE Instance Parameter&#34;&gt;&lt;figcaption id=&#34;caption-attachment-755&#34; class=&#34;wp-caption-text&#34;&gt;ArcSDE Instance Parameter&lt;/figcaption&gt;&lt;/figure&gt;&lt;/p&gt;
&lt;p&gt;Since we have multiple ArcSDE geodatabases, I like to have a handy-dandy sticky note with all the geodatabases and their respective ports on the side of my monitor.&lt;/p&gt;
&lt;p&gt;But when that is not handy and I can never remember the ArcSDE command line syntax to get a list of instances and their ports–I mean remembering &amp;lsquo;&lt;a href=&#34;http://help.arcgis.com/en/geodatabase/10.0/admin_cmds/support_files/admincmdref.htm&#34; target=&#34;_blank&#34;&gt;sdeservice -o list&lt;/a&gt;&amp;rsquo; is difficult at my age.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2013/02/sdeservicelist.png&#34; alt=&#34;sdeservicelist&#34;&gt;&lt;/p&gt;
&lt;p&gt;The quickest and most reliable way I&amp;rsquo;ve found to get the instance number is just to check the properties of your SDE connection file in ArcCatalog, right-click on it and select &amp;lsquo;Connection Properties&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2013/02/connectionproperties.png&#34; alt=&#34;connectionproperties&#34;&gt;&lt;/p&gt;
&lt;p&gt;And the port is right there in the service entry (5164).&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2013/02/connectionproperties2.png&#34; alt=&#34;connectionproperties2&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>I&#39;m Back!</title>
      <link>https://maprantala.com/2013/02/24/im-back/</link>
      <pubDate>Sun, 24 Feb 2013 11:04:35 -0600</pubDate>
      <guid>https://maprantala.com/2013/02/24/im-back/</guid>
      <description>&lt;p&gt;Ok, it has been to long since I last posted and I thank those few people who asked If I had suffered a Segmentation Violation or something.&lt;/p&gt;
&lt;p&gt;By means of a brief explanation, I changed jobs last summer, going back to a previous employer in a very different role than what I&amp;rsquo;ve ever had before. It was a challenging and difficult and one that I had minimal success at but, in the end, didn&amp;rsquo;t work out. Mostly because I wasn&amp;rsquo;t a good fit for a variety of reasons including, not surprisingly, geography!  I was mostly tele-commuting because the office was two hours away. I really needed to be in the office more than I was and I wasn&amp;rsquo;t in a position to relocate.&lt;/p&gt;
&lt;p&gt;During my time with that employer I was doing less technical stuff and just did not feel the urgency to be blogging.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve left that job (which was very hard to do because I felt like I was abandoning friends) and have a short-term gig with the employer I left in the summer which will be almost entirely technical work, so I hope to crank out some more technical blog posts.&lt;/p&gt;
&lt;p&gt;Also, I&amp;rsquo;m hoping to shift my career focus somewhat. I&amp;rsquo;ve been somewhat stuck as a desktop guy–developing mostly desktop applications.  I&amp;rsquo;ve wanted to do more web development stuff but never made the switch. I&amp;rsquo;m hoping to build my web skills in the short-term and have been cramming on topics like Java, HTML5, CSS, Map Server, Geo Server, php, jQuery, and anything else that might enhance my web-abilities.&lt;/p&gt;
&lt;p&gt;So expect some changes to the blog and I thank everyone who comes to the blog, while the numbers aren&amp;rsquo;t huge, I am still surprised at how many people find their way here.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>SDEINTERCEPT and SDEINTERCEPTLOC</title>
      <link>https://maprantala.com/2012/08/01/sdeintercept-and-sdeinterceptloc/</link>
      <pubDate>Wed, 01 Aug 2012 07:17:41 -0500</pubDate>
      <guid>https://maprantala.com/2012/08/01/sdeintercept-and-sdeinterceptloc/</guid>
      <description>&lt;p&gt;Awhile ago, I had a ArcSDE problem that required &lt;a href=&#34;http://support.esri.com/en/&#34;&gt;ESRI technical support&lt;/a&gt; to help trouble-shoot. The problem was odd but was resolved by rebooting the server.&lt;br&gt;
During the process, though, the support person had me set a couple of environment variables for logging SDE activity on the client machine.&lt;/p&gt;
&lt;p&gt;The settings were SDEINTERCEPT and SDEINTERCEPTLOC.&lt;/p&gt;
&lt;p&gt;From &lt;a href=&#34;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002n00000018000000&#34;&gt;ESRI&amp;rsquo;s Help&lt;/a&gt;, SDEINTERCEPT specifies what activity to log and SDEINTERCEPTLOC specifies where to save the log files.&lt;/p&gt;
&lt;p&gt;I recently deleted the directory I made for the log files but did not remove the variables and I noticed that one of my python scripts reported a weird error (but continued to run, I think). I tracked it back to these variables and realized what I had done.&lt;/p&gt;
&lt;p&gt;Googling SDEINTERCEPTLOC did lead me to some helpful information like:&lt;/p&gt;
&lt;p&gt;The &lt;a href=&#34;http://sdeintercept.wordpress.com/2011/11/22/sde-user-permissions/&#34;&gt;SDEINTERCEPT blog&lt;/a&gt; where Ken posts ArcSDE help.&lt;/p&gt;
&lt;p&gt;This &lt;a href=&#34;http://blogs.esri.com/esri/arcgis/2008/09/05/digging-deeper-troubleshooting-geoprocessing-errors-when-using-arcsde-data/&#34;&gt;ESRI post&lt;/a&gt; about troubleshotting geoprocessing problems.&lt;/p&gt;
&lt;p&gt;And this &lt;a href=&#34;http://support.esri.com/en/knowledgebase/techarticles/detail/35704&#34;&gt;ESRI technical&lt;/a&gt; article about diagnosing ArcSDE Connections.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Unsupported Arc: &#39;Rebox&#39;ing or updating the extent of a feature class</title>
      <link>https://maprantala.com/2012/06/05/unsupported-arc-reboxing-or-updating-the-extent-of-a-feature-class/</link>
      <pubDate>Tue, 05 Jun 2012 21:16:28 -0500</pubDate>
      <guid>https://maprantala.com/2012/06/05/unsupported-arc-reboxing-or-updating-the-extent-of-a-feature-class/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve found that sometimes I can not find the answer to a question until I know the answer &amp;amp; then it becomes ridiculously easy to find the answer.&lt;/p&gt;
&lt;p&gt;One small annoying thing that I never spent much time was when you delete features from a feature class making it significantly smaller but the envelope does not get re-sized so the zoom extent (still the original extent) is too large. This often happens to use when we convert tables to an XY theme and there are blank records–most of our data shows in Minnesota but there are some in Oklahoma (I think). Once we eliminate or correct the blank records, our data view still pops out to include a large section of the United States even though we only have data in Minnesota.&lt;/p&gt;
&lt;p&gt;A long, long time ago, &lt;a href=&#34;http://forums.arcgis.com/forums/54-ArcInfo-Workstation&#34; target=&#34;_blank&#34;&gt;Workstation ArcInfo&lt;/a&gt; had a simple command, &lt;a href=&#34;http://resources.esri.com/help/9.3/geoprocessing/pdf/arcinfo_commands.pdf&#34; target=&#34;_blank&#34;&gt;Rebox&lt;/a&gt;, for just this purpose (actually it still does, I just don&amp;rsquo;t get to use it anymore)–it shrunk the extent to the smallest rectangle required to enclose all the data. Up until today, I thought &lt;a href=&#34;http://forums.esri.com/Thread.asp?c=93&amp;f=993&amp;t=184832&#34; target=&#34;_blank&#34;&gt;the request&lt;/a&gt; for this feature was completely ignored.&lt;/p&gt;
&lt;p&gt;While researching something else, I was digging around in the sde tables and found one, sde.sde_layers, that had the interesting fields, minx, miny, maxx, and maxy. My quick &amp;amp; dangerous test (I performed it on a throw-away feature class in a throw-away geodatabase) gave me the results I wanted–once I loaded the feature class into ArcMap, the extent was a nice, tight rectangle around my features.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/06/extent1.png&#34; alt=&#34;Extent&#34;&gt;&lt;/p&gt;
&lt;p&gt;Is this a supported way to Rebox the extent? No.&lt;/p&gt;
&lt;p&gt;Is it recommend by ESRI or me? No.&lt;/p&gt;
&lt;p&gt;Will it screw up your entire geodatabase, making you lose all your data &amp;amp; costing you your job? Probably not but do you want to take that chance?&lt;/p&gt;
&lt;p&gt;Will it get the job done? Maybe.  But in the process of writing this post, I found two safer ways to go about it. First, the straight-forward, sde command-line way that probably always existed that I never found until today, &lt;a href=&#34;http://help.arcgis.com/en/geodatabase/10.0/admin_cmds/support_files/datamgmt/sdelayer.htm&#34; target=&#34;_blank&#34;&gt;sdelayer -o alter had an -E option to reset the extent&lt;/a&gt;, including the ability to either specify it or have sde calculate it. Ok, that is usable for one person in our organization.&lt;/p&gt;
&lt;p&gt;Previously, we had found either a VBA or other tool for doing this but had minimal success with it. Today, I found an &lt;a href=&#34;http://resources.arcgis.com/gallery/file/Geoprocessing-Model-and-Script-Tool-Gallery/details?entryID=AE907673-1422-2418-A092-D7AAF6A16E6C&#34; target=&#34;_blank&#34;&gt;ArcGIS 10 Add-In&lt;/a&gt; that is suppose to do the same thing. In my experiments (sample size n=1) it worked perfectly. If you need this sort of functionality, I would recommend trying out this Add-In first, if that fails go the sde command line route. Use the direct SQL method at your own risk!&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty python: Converting a text file to audio (.wav)</title>
      <link>https://maprantala.com/2012/05/31/quick-dirty-python-converting-a-text-file-to-audio-.wav/</link>
      <pubDate>Thu, 31 May 2012 23:12:28 -0500</pubDate>
      <guid>https://maprantala.com/2012/05/31/quick-dirty-python-converting-a-text-file-to-audio-.wav/</guid>
      <description>&lt;p&gt;This is a bit of a tangent but for some crazy reason, I wanted to convert some text to audio so I could listen to it while I drive. A quick Google search left me without any freeware that could handle the 53 page document–there are some cool websites that do text to mp3 like &lt;a href=&#34;http://vozme.com/index.php?lang=en&#34; target=&#34;_blank&#34;&gt;vozme &lt;/a&gt;and &lt;a href=&#34;http://www.yakitome.com/&#34; target=&#34;_blank&#34;&gt;YAKiToMe&lt;/a&gt;! but they didn&amp;rsquo;t convert the whole document. I then found &lt;a href=&#34;http://www.cs.unc.edu/Research/assist/doc/pytts/&#34; target=&#34;_blank&#34;&gt;pyTTS&lt;/a&gt;, a python package that serves as a wrapper to the &lt;a href=&#34;http://msdn.microsoft.com/en-us/library/ms723627%28v=vs.85%29&#34; target=&#34;_blank&#34;&gt;Microsoft Speech API (SAPI) &lt;/a&gt;, which has &lt;a href=&#34;http://en.wikipedia.org/wiki/Microsoft_Speech_API&#34; target=&#34;_blank&#34;&gt;been in version 5 since 2000.&lt;/a&gt; But I didn&amp;rsquo;t easily find a version of pyTTS for python 2.6. So I decided to see if I could roll my own.&lt;/p&gt;
&lt;p&gt;As it turns out, getting python to talk using SAPI is relatively easy. Reading a plain text file can be done in a few lines.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; comtypes.client &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; CreateObject

infile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;c:/temp/text.txt&amp;#34;&lt;/span&gt;

engine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; CreateObject(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SAPI.SpVoice&amp;#34;&lt;/span&gt;)

f &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; open(infile, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;r&amp;#39;&lt;/span&gt;)
theText &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;read()
f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;close()

engine&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;speak(theText)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And it wasn&amp;rsquo;t that much more to have it write out a .wav file:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; comtypes.client &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; CreateObject

engine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; CreateObject(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SAPI.SpVoice&amp;#34;&lt;/span&gt;)
stream &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; CreateObject(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SAPI.SpFileStream&amp;#34;&lt;/span&gt;)

infile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;c:/temp/text.txt&amp;#34;&lt;/span&gt;
outfile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;c:/temp/text4.wav&amp;#34;&lt;/span&gt;
stream&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Open(outfile, SpeechLib&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SSFMCreateForWrite)
engine&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AudioOutputStream &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; stream

f &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; open(infile, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;r&amp;#39;&lt;/span&gt;)
theText &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;read()
f&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;close()

engine&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;speak(theText)

stream&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Close()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And with that chunk of code, I was able to convert my 54 page document into a 4 hour long .wav file (over 600 MB) that I used another software package to convert to .mp3 (200 MB). The voice is a bit robotic but not too bad, I just hope the content that I converted (a database specification standard) doesn&amp;rsquo;t put me to sleep while I drive.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty arcpy: Autopan ArcMap using arcpy</title>
      <link>https://maprantala.com/2012/05/02/quick-dirty-arcpy-autopan-arcmap-using-arcpy/</link>
      <pubDate>Wed, 02 May 2012 05:19:40 -0500</pubDate>
      <guid>https://maprantala.com/2012/05/02/quick-dirty-arcpy-autopan-arcmap-using-arcpy/</guid>
      <description>&lt;p&gt;Question: How do I get ArcMap to automatically pan through an area.&lt;/p&gt;
&lt;p&gt;As I mentioned in a &lt;a href=&#34;https://maprantala.com/2012/04/30/building-a-loc%E2%80%A6f-bing-imagery/&#34;&gt;previous post&lt;/a&gt;, I recently had the need to have ArcMap automatically pan through a project area. My first attempt was to print a series of data-driven pages (using a fishnet polygon layer as the index) this but that did not accomplish what I needed so I switched to arcpy, which made the task simple enough. Nothing special or tricky about this code, but just did not find it anywhere else.&lt;/p&gt;
&lt;p&gt;The one thing to note is that I have a 1 second pause between pans–this was to allow image tiles to download. You will need to adjust the delay to meet your needs. &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20120427_AutoPan.zip&#34;&gt;The toolbox and code can also be downloaded&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import sys,arcpy,datetime
inLayer = sys.argv[1]

def printit(inMessage):
    print inMessage
    arcpy.AddMessage(inMessage)

mxd = arcpy.mapping.MapDocument(&amp;quot;CURRENT&amp;quot;)

arcpy.MakeFeatureLayer_management(inLayer, &amp;quot;indexLayer&amp;quot;)
cur=arcpy.SearchCursor(&amp;quot;indexLayer&amp;quot;)

df = arcpy.mapping.ListDataFrames(mxd)[0]
newExtent = df.extent

iCount = 0
iTotal = (arcpy.GetCount_management(&amp;quot;indexLayer&amp;quot;).getOutput(0))

for row in cur:
    thisPoly = row.getValue(&amp;quot;Shape&amp;quot;)
    newExtent.XMin, newExtent.YMin = thisPoly.extent.XMin, thisPoly.extent.YMin
    newExtent.XMax, newExtent.YMax = thisPoly.extent.XMax, thisPoly.extent.YMax
    df.extent = newExtent
    time.sleep(1)
    iCount+=1
    printit(&amp;quot;Panned to feature {0} of {1}&amp;quot;.format(iCount,iTotal))

del row
del cur
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Building a local, permanent cache of Bing Imagery.</title>
      <link>https://maprantala.com/2012/04/30/building-a-local-permanent-cache-of-bing-imagery./</link>
      <pubDate>Mon, 30 Apr 2012 05:28:15 -0500</pubDate>
      <guid>https://maprantala.com/2012/04/30/building-a-local-permanent-cache-of-bing-imagery./</guid>
      <description>&lt;p&gt;I recently had an internal request to capture and store the Bing imagery for an area for future use. The user was interested in some specific images that were taken after a fire, making the ground surface-and certain geological features-much more visible. His concern was that in the future this imagery might get replaced with updated imagery taken when the vegetation has grown back.&lt;/p&gt;
&lt;p&gt;Since it is unknown when/how this data might be used by us, we mostly wanted to capture it now &amp;amp; find a way to use it.&lt;/p&gt;
&lt;p&gt;While we initiated the process of finding out what agency the data was available through, we also came up with a quick &amp;amp; dirty way to download the data.&lt;/p&gt;
&lt;p&gt;Since ArcGIS 10 has made the process of loading cached basemap data a trivial process through ArcGIS Online, I have not used it much since taking a &lt;a href=&#34;https://maprantala.com/2010/09/09/arcbrutile/&#34;&gt;quick first look&lt;/a&gt; at it in 2010.&lt;/p&gt;
&lt;p&gt;After removing my old, forgotten version and installing the latest, shiniest version of ArcBruTile, I verified it was able to display the imagery we wanted. ArcBruTile can be used to &amp;lsquo;display maps from &lt;a href=&#34;http://www.openstreetmap.org/&#34;&gt;OpenStreetMap&lt;/a&gt;, &lt;a href=&#34;http://www.bing.com/maps/&#34;&gt;Bing&lt;/a&gt;,  &lt;a href=&#34;http://www.spatialcloud.com/&#34;&gt;SpatialCloud&lt;/a&gt;, &lt;a href=&#34;http://www.mapquest.com/&#34;&gt;MapQues&lt;/a&gt;t,  &lt;a href=&#34;http://www.europa-tech.com/&#34;&gt;Europa Technologies&lt;/a&gt;, &lt;a href=&#34;http://www.vr-theworld.com/&#34;&gt;VR-TheWorld Online&lt;/a&gt;, &lt;a href=&#34;http://www.mapbox.com/&#34;&gt;Mapbox&lt;/a&gt;, &lt;a href=&#34;http://www.stamen.com/&#34;&gt;Stamen Design&lt;/a&gt; and others in ArcGIS Desktop&amp;rsquo;. The cool thing for me was it builds a local cache in an open format–a bunch of jpeg files in a directory structure. All I had to do was clear the cache, and pan through the area of interest at the desired scale.&lt;/p&gt;
&lt;p&gt;I could either spend many long boring hours manually panning, go through the process of renting a chimp to do it for me, or write some code to do it for me. I ended up making a fishnet of the area of interest and wrote a python script to pan through the area (to be posted).&lt;/p&gt;
&lt;p&gt;After I had the images, I ended up build a Mosaic Dataset and added the images to it.  The last trick I that I had to figure out–and really I just found in it &lt;a href=&#34;http://forums.arcgis.com/&#34;&gt;ArcForums&lt;/a&gt;–was how to &lt;a href=&#34;http://forums.arcgis.com/threads/50978-Relative-paths-in-mosaic-datasets?p=193579#post193579&#34;&gt;create a mosaic dataset using relative paths&lt;/a&gt;. Can not be done, at least in 10, but by using the &amp;lsquo;Repair…&amp;rsquo; option to reset paths, you can make the mosaic dataset portable enough that if the reason you wanted to use relative paths was so you could move the data around or to other machines, you can. Just need to repair the paths.&lt;/p&gt;
&lt;p&gt;So now, until we can actually track down the original data, we at least have a usable, archive of the imagery we wanted to preserve and have a way to access it in the field in a non-connected environment.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Identifying Unique Cases, Single Field</title>
      <link>https://maprantala.com/2012/04/28/arcmap-field-calculator-identifying-unique-cases-single-field/</link>
      <pubDate>Sat, 28 Apr 2012 05:55:34 -0500</pubDate>
      <guid>https://maprantala.com/2012/04/28/arcmap-field-calculator-identifying-unique-cases-single-field/</guid>
      <description>&lt;p&gt;Seems like a lot of people are finding the ArcMap Field Calculator &lt;a href=&#34;https://maprantala.com/category/esri/arcmap-esri/field-calculator/&#34;&gt;examples&lt;/a&gt; that I have posted useful so I will make an effort to post more of them. Most posts are generated after I do something and think that others might want to know how to do it. (Or so I can go back and remember how I did something without re-inventing it).&lt;/p&gt;
&lt;p&gt;Something I did today was create a field (!Case!) and then populated this with a unique identifier for each different value (case) that occurred in a different field (!Feature!).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Note: python&amp;rsquo;s &lt;em&gt;index&lt;/em&gt; statement is a 0-based search so the first case will have the value 0, the second will have 1, and so on. If you want to start the results at 1, you can make the last line: &amp;lsquo;return caseList.index(inValue) + 1&amp;rsquo;.&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The basic structure for this is shown:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;caseList = [ ]

def returnCase(inValue):
   global caseList

   if not inValue in caseList:
      caseList.append(inValue)

   return caseList.index(inValue)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;img class=&#34;aligncenter size-full wp-image-700&#34; title=&#34;Case&#34; src=&#34;https://i0.wp.com/maprantala.com/wp-content/uploads/2012/04/case.png?resize=614%2C449&#34; alt=&#34;&#34; width=&#34;614&#34; height=&#34;449&#34; data-recalc-dims=&#34;1&#34; /&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Identifying Unique Cases, Multiple Fields</title>
      <link>https://maprantala.com/2012/04/23/arcmap-field-calculator-identifying-unique-cases-multiple-fields/</link>
      <pubDate>Mon, 23 Apr 2012 06:06:25 -0500</pubDate>
      <guid>https://maprantala.com/2012/04/23/arcmap-field-calculator-identifying-unique-cases-multiple-fields/</guid>
      <description>&lt;p&gt;You may have noticed that this post–&lt;a href=&#34;http://wp.me/pVrsJ-bf&#34;&gt;ArcMap Field Calculator: Identifying Unique Cases, Single Field&lt;/a&gt;–specifies &amp;lsquo;Single Field&amp;rsquo;. Yes, that was my version of a cliff-hanger post.&lt;/p&gt;
&lt;p&gt;The basic structure I listed in that post can be expanded on to satisfy your needs. The example in my earlier post was case sensitive for example, you could modify it so it treats &amp;lsquo;a&amp;rsquo; the same as &amp;lsquo;A&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;Today&amp;rsquo;s example groups records into different cases based off the values of two fields, !county_c! and !feature! and required only minor modifications.&lt;/p&gt;
&lt;p&gt;The calling line was modified from:&lt;/p&gt;
&lt;p&gt;From:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;   returnCase(&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;feature&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;To:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;   returnCase(&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;county_c&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;,&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;feature&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;to accommodate passing both values.&lt;/p&gt;
&lt;p&gt;The function definition likewise was modified to accept two values, this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;   &lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;returnCase&lt;/span&gt;(inValue1):
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;to:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;  &lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;returnCase&lt;/span&gt;(inValue1, inValue2)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And this line was added, creating a list from the two values passed in:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;   inValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [inValue1, inValue2]
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;**(Note: The same results could have be achieved by using the original function by creating the list in the calling statement:  returnCase([!county_c!,!feature!] )&lt;br&gt;
**&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;caseList = [ ]

def returnCase(inValue1, inValue2):
   inValue = [inValue1, inValue2]
   global caseList

   if not inValue in caseList:
      caseList.append(inValue)

   return caseList.index(inValue)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/04/case_multiple.png&#34; alt=&#34;Case_Multiple&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Beware of Integer Division!</title>
      <link>https://maprantala.com/2012/04/02/arcmap-field-calculator-beware-of-integer-division/</link>
      <pubDate>Mon, 02 Apr 2012 05:34:54 -0500</pubDate>
      <guid>https://maprantala.com/2012/04/02/arcmap-field-calculator-beware-of-integer-division/</guid>
      <description>&lt;p&gt;Apparently, if you post one time about ArcMap field calculator, you&amp;rsquo;re bound to get additional questions.  After &lt;a href=&#34;https://maprantala.com/2012/03/28/arcmap-field-calculator-text-to-double/&#34;&gt;my recent post&lt;/a&gt; about using field calculator to convert text values to numeric, someone asked about a problem they were having with another calculation they were having.&lt;/p&gt;
&lt;p&gt;The underlying problem was that python 2.6, which is installed with ArcGIS 10, &lt;a href=&#34;http://docs.python.org/release/2.6.7/library/stdtypes.html#numeric-types-int-float-long-complex&#34;&gt;uses integer division&lt;/a&gt; when both the numerator and denominator are integers. The result of integer division is an integer rounded towards negative infinity.&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;re not aware of this (or forget) then you open yourself up to some unexpected results–they can be especially hard to catch if you are using it within a larger block of code.&lt;/p&gt;
&lt;p&gt;In this example, I&amp;rsquo;m calculating a percentage but the result is 0 for all the records because of the rounding.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/calc1.png&#34; alt=&#34;Calc1&#34;&gt;&lt;/p&gt;
&lt;p&gt;The easiest thing to do in this simple example is just convert one of the two value to a non-integer value. This can be done by multiplying by 1.0 (not just &amp;lsquo;1&amp;rsquo;, you need to include the &amp;lsquo;.0&amp;rsquo;) which is a float datatype. Multiplying one of the values by a float makes that value a float and integer division no longer applies &amp;amp; we end up with a happy GISer.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/calc2.png&#34; alt=&#34;Calc2&#34;&gt;&lt;/p&gt;
&lt;p&gt;Another option if you are using a Codeblock is to include &amp;lsquo;from __future__ import division&amp;rsquo; in your code block. Python is slowly moving away from using integer division and the _\&lt;em&gt;_future__&lt;/em&gt; module overrides the default behavior.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/calc3.png&#34; alt=&#34;Calc3&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Text to Double</title>
      <link>https://maprantala.com/2012/03/28/arcmap-field-calculator-text-to-double/</link>
      <pubDate>Wed, 28 Mar 2012 05:23:32 -0500</pubDate>
      <guid>https://maprantala.com/2012/03/28/arcmap-field-calculator-text-to-double/</guid>
      <description>&lt;p&gt;Received a request yesterday asking how to use the ArcMap Calculator to copy values from a Text field to a Double field using python syntax.  As any good blogger would do, I immediately thought, &amp;lsquo;Awesome! Someone&amp;rsquo;s question is the perfect topic for a new blog post&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;The python parser is actually pretty good at casting values on the fly so if the values in your text field (!Day! in my example) are valid values that can be converted to a Double value, it is as simple as just setting the formula to be the text field. In my example case, I wanted to copy the value from !Day! to !DecDay! so I set the formula to be DecDay = !Day!.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/tonumber1.png&#34; alt=&#34;ToNumber1&#34;&gt;&lt;/p&gt;
&lt;p&gt;That should work fine if you have clean values in your text field. In the example above, you might notice I had a selected set of 3 records that all had numeric values in the !Day! field. When I included the fourth row, which does not have a numeric value in the text field, I get this error message (&amp;lsquo;There was a failure during processing, check the Geoprocessing Results window for details.&amp;rsquo; when I use the same formula. Time to add in an error exception.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/tonumber2b.png&#34; alt=&#34;ToNumber2b&#34;&gt;&lt;/p&gt;
&lt;p&gt;For more advanced logic, the Field Calculator dialog allows you to use a python function if you check on the &amp;lsquo;Show Codeblock&amp;rsquo; option.  In the &amp;lsquo;Pre-Logic Script Code&amp;rsquo; area (Seriously, who at ESRI came up with that name?) I entered the following function. If the value in my text field (!Day!) can be cast to a number of type float, that value is returned. If the cast is unsuccessful (IE the value in !Day! is not a number), then I return -99.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;toNum&lt;/span&gt;(inValue):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
      outValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; float(inValue)
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; outValue
   &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;99&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then in the formula portion of the dialog, I call the function, passing the value in the !Day! field: DecDay = toNum(!Day!).&lt;br&gt;
&lt;img src=&#34;https://maprantala.com/images/2012/03/tonumber2.png&#34; alt=&#34;OptioToNumber2ns&#34;&gt;&lt;/p&gt;
&lt;p&gt;Now, if you would prefer not to set all the records with non-numeric values to be -99 or other error value, not return anything. To do this, I replaced the &amp;lsquo;return -99&amp;rsquo; in the original function with a filler line (&amp;lsquo;doNothing = 4&amp;rsquo;) since the try block needs an non-empty except clause.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;toNum&lt;/span&gt;(inValue):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;try&lt;/span&gt;:
      outValue &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; float(inValue)
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; outValue
   &lt;span style=&#34;color:#66d9ef&#34;&gt;except&lt;/span&gt;:
      doNothing &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/tonumber3.png&#34; alt=&#34;ToNumber3&#34;&gt;&lt;br&gt;
And that should leave the values in the double field unscathed in your records with non-numeric values in the text field.&lt;/p&gt;
&lt;p&gt;Shameless Plug: Check out my other blog posts on using ArcMap&amp;rsquo;s Field Calculator to &lt;a href=&#34;https://maprantala.com/2011/03/08/calculating-geometry-using-arcpy-in-field-calculator/&#34;&gt;calculate geometry&lt;/a&gt; and converting a date value to an &lt;a href=&#34;https://maprantala.com/2011/10/06/field-calculator-arcpy-date-to-decimal-function/&#34;&gt;8 digit numeric value&lt;/a&gt;.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Domain Sorter Add-In Version 1.1</title>
      <link>https://maprantala.com/2012/03/21/domain-sorter-add-in-version-1.1/</link>
      <pubDate>Wed, 21 Mar 2012 18:19:03 -0500</pubDate>
      <guid>https://maprantala.com/2012/03/21/domain-sorter-add-in-version-1.1/</guid>
      <description>&lt;p&gt;Almost &lt;a href=&#34;https://maprantala.com/2011/05/03/sorting-a-coded-value-domain-add-in-arcgis-10/&#34;&gt;a year ago&lt;/a&gt;, I updated ERSI&amp;rsquo;s &lt;a href=&#34;http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Geodatabase/Schema_Creation_and_Management/Sort_a_domain/e826c5a8-9740-4f0b-86b6-d3b834735574.htm&#34;&gt;Domain Sort code for VB 6&lt;/a&gt; to work with ArcGIS 10. Recently, I had a comment that this Add-In caused ArcCatalog to explode if you had an open OLE connection. When I tested it, it turned out the reports were accurate.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images//2012/03/arccatalog.png&#34; alt=&#34;ArcCatalog&#34;&gt;&lt;/p&gt;
&lt;p&gt;I got around to adding in a Try-Catch around the offending chunk of code &amp;amp; it is now better than ever. You can download just the &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/DomainSorter.esriAddIn&#34;&gt;Add-In&lt;/a&gt; or the &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20120321_DomainSort.zip&#34;&gt;Add-In with source code&lt;/a&gt; or get it from &lt;a href=&#34;http://resources.arcgis.com/gallery/file/arcobjects-net-api/details?entryID=B5E1BB12-1422-2418-34B7-D3A6908560FA&#34;&gt;ESRI&amp;rsquo;s ArcGIS Resource Center&lt;/a&gt;.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quicker and Cleaner python recursive folder search</title>
      <link>https://maprantala.com/2012/03/14/quicker-and-cleaner-python-recursive-folder-search/</link>
      <pubDate>Wed, 14 Mar 2012 17:28:59 -0500</pubDate>
      <guid>https://maprantala.com/2012/03/14/quicker-and-cleaner-python-recursive-folder-search/</guid>
      <description>&lt;p&gt;As contributor of the day, &lt;a href=&#34;http://www.cleanstick.net/jason/&#34;&gt;Jason Scheirer&lt;/a&gt;, &lt;a href=&#34;https://maprantala.com/2012/03/13/quick-dirty-python-recursive-folder-search-2/#comments&#34;&gt;pointed out&lt;/a&gt;, python has a simple, direct way to browse through the subdirectories of a directory–&lt;a href=&#34;http://docs.python.org/library/os.html#os.walk&#34;&gt;os.walk&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Here is a bare-bones example of using it to print out the subdirectories in a path. The files variable of the 3-tuple is a list of files similar to the dirs variable that I loop through.&lt;/p&gt;
&lt;p&gt;Thanks Jason for pointing out something I missed.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os

theDir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;c:/temp/&amp;#39;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; root, dirs, files &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;walk(theDir,True,None):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; idir &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; dirs:
        &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;     directory:   {0}/{1}&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;format(root,idir)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/dirstalker21.png&#34; alt=&#34;DirStalker2&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty python recursive folder search</title>
      <link>https://maprantala.com/2012/03/13/quick-dirty-python-recursive-folder-search/</link>
      <pubDate>Tue, 13 Mar 2012 15:55:55 -0500</pubDate>
      <guid>https://maprantala.com/2012/03/13/quick-dirty-python-recursive-folder-search/</guid>
      <description>&lt;p&gt;Someone asked how to have python recursively search a folder structure. There may be a better way but this is how I typically do it–it basically starts with one directory and loops through the contents compiling a list of sub-directories as it goes through the contents.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2012/03/dirstalker.png&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; os

theDir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;c:/temp/&amp;#39;&lt;/span&gt;
theDirList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
theDirList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(theDir)

&lt;span style=&#34;color:#66d9ef&#34;&gt;while&lt;/span&gt; len(theDirList)&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;:
   newDirList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []
   &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iDir &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; theDirList:
      &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; iDir
      &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iFile &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;glob(iDir&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/*&amp;#34;&lt;/span&gt;):
         &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;isdir(iFile)):
            newDirList&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(iFile)

   theDirList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; newDirList
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: ArcPy Date to Decimal Function</title>
      <link>https://maprantala.com/2011/10/06/arcmap-field-calculator-arcpy-date-to-decimal-function/</link>
      <pubDate>Thu, 06 Oct 2011 21:08:35 -0500</pubDate>
      <guid>https://maprantala.com/2011/10/06/arcmap-field-calculator-arcpy-date-to-decimal-function/</guid>
      <description>&lt;p&gt;One of the standards in our databases is to store dates as 8-digit integer values in the format of yyyymmdd. This requires us to occasionally convert values from date fields into this format.&lt;/p&gt;
&lt;p&gt;We can do this in the ArcMap Field Calculator using this arcpy function:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;datetodouble&lt;/span&gt;(inNum):
   splitList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; str(inNum)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;split(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt;)
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt;  splitList [&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]  &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;0&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; splitList [&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;])[&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;:]  &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;0&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; splitList [&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;])[&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;:]
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/10/datetodouble.png&#34; alt=&#34;Date To Double&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Data Extration Failed Reverse Proxy Time-out</title>
      <link>https://maprantala.com/2011/08/18/data-extration-failed-reverse-proxy-time-out/</link>
      <pubDate>Thu, 18 Aug 2011 19:55:47 -0500</pubDate>
      <guid>https://maprantala.com/2011/08/18/data-extration-failed-reverse-proxy-time-out/</guid>
      <description>&lt;p&gt;Testing one of our geodata services, we discovered that it allowed us to extract a portion of our feature class but when we tried to extract the entire data set, we received this Data Extraction error: Data extraction failed. Proxy or Gateway Server did not allow the URL. Check with your LAN administrator that Proxy or Gateway server is configured to allow the URL.&lt;/p&gt;
&lt;p&gt;The fact that I was able to extract a portion of the data and I could see the entire geodatabase get made and zipped led me to believe it was more of time-out issue.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/08/dataextractionfailed.png&#34; alt=&#34;Data Extraction Failed&#34;&gt;&lt;/p&gt;
&lt;p&gt;Reading through this thread at &lt;a href=&#34;http://forums.esri.com/thread.asp?c=158&amp;amp;f=1696&amp;amp;t=273750&#34;&gt;ArcForum&lt;/a&gt; led to some good information.  But Thomas&#39; comment that he was using &amp;lsquo;IIS7 for my reverse proxy server&amp;rsquo; and had to change one more setting led me to the solution.  In Server Manager, the default Proxy Time-Out is set at 30 seconds by default.  I bumped that up, 60 seconds shown below but I ended up going to 300 seconds and the problem was resolved.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/08/servermanager.jpg&#34; alt=&#34;fsda&#34;&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-628&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Create a Unique ID</title>
      <link>https://maprantala.com/2011/07/28/arcmap-field-calculator-create-a-unique-id/</link>
      <pubDate>Thu, 28 Jul 2011 20:08:13 -0500</pubDate>
      <guid>https://maprantala.com/2011/07/28/arcmap-field-calculator-create-a-unique-id/</guid>
      <description>&lt;p&gt;One of the common functions I have to do is assign each record in a feature class with a unique identifier–normally just a sequential number from 1 to N.  In ArcView 3.x, the formula was simply &amp;lsquo;rec + 1&amp;rsquo; if I wanted to start with the number 1.&lt;/p&gt;
&lt;p&gt;In ArcGIS, the process got a little more complex–you had to write a little VBA in Field Calculator as &lt;a href=&#34;http://support.esri.com/en/knowledgebase/techarticles/detail/27427&#34;&gt;described by ESRI&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;While this option still exists in ArcGIS 10, I believe it will disappear when 10.1 comes out and VBA support is completely eliminated.  But it is doable using Python which will continue to be supported.&lt;/p&gt;
&lt;p&gt;Googling around, I did not find an exact answer but Dave Verbyla, Professor of GIS/Remote Sensing at the University of Alaska has a &lt;a href=&#34;http://nrm.salrm.uaf.edu/~dverbyla/nrm638/lectures/Python_field_calculator.pdf&#34;&gt;posted some samples&lt;/a&gt; that served as a good starting point.&lt;/p&gt;
&lt;p&gt;In the Pre-Logic Script Code box, I declare a variable (counter) and a function. Then in the formula, I call the function.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;counter &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;uniqueID&lt;/span&gt;():
  &lt;span style=&#34;color:#66d9ef&#34;&gt;global&lt;/span&gt; counter
  counter &lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; counter
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/07/fc-arcpy.png&#34; alt=&#34;Field Calculator&#34;&gt;&lt;/p&gt;
&lt;p&gt;While composing this post, I actually wanted a concatenated value; &amp;lsquo;OC&amp;rsquo; plus an 8 character numeric sequential number starting at OC00000001 so the actual code is shown below:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/07/fc-arcpy2.png&#34; alt=&#34;Field Calculator&#34;&#34;&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-620&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcGIS Add-In Custom Mouse Cursor</title>
      <link>https://maprantala.com/2011/07/19/arcgis-add-in-custom-mouse-cursor/</link>
      <pubDate>Tue, 19 Jul 2011 20:47:03 -0500</pubDate>
      <guid>https://maprantala.com/2011/07/19/arcgis-add-in-custom-mouse-cursor/</guid>
      <description>&lt;p&gt;I was working on a project and wanted my own custom mouse cursor and did not easily find a way to make your own in ESRI&amp;rsquo;s instructions.  But, once you know how to do it, it is pretty easy.  In Visual Studio, Add a New Item:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/07/addresource.png&#34; alt=&#34;Add Resource&#34;&gt;&lt;/p&gt;
&lt;p&gt;Add a Cursor File:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/07/selectcursor.png&#34; alt=&#34;SelectCursor&#34;&gt;&lt;/p&gt;
&lt;p&gt;You can edit your cursor with the editor program in Visual Studio.  Once you satisfied with how it looks, make sure that the Build Action on the cursor is &amp;lsquo;Embedded Resource&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/07/embedded.png&#34; alt=&#34;Embedded&#34;&gt;&lt;/p&gt;
&lt;p&gt;Then you can set your cursor with two lines of code. Note that my cursor is in my QDI.QdiAddIn Namespace:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Dim pCursorStream As System.IO.Stream = Me.GetType.Assembly.GetManifestResourceStream(&amp;quot;QDI.QdiAddIn.NewCursor.cur&amp;quot;)
MyBase.Cursor = New System.Windows.Forms.Cursor(pCursorStream)

&lt;/code&gt;&lt;/pre&gt;&lt;div id=&#34;geo-post-599&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Debugging a Python Scheduled Task</title>
      <link>https://maprantala.com/2011/07/11/debugging-a-python-scheduled-task/</link>
      <pubDate>Mon, 11 Jul 2011 18:11:13 -0500</pubDate>
      <guid>https://maprantala.com/2011/07/11/debugging-a-python-scheduled-task/</guid>
      <description>&lt;p&gt;I have been working on a python script that I want (NEED) to run as a scheduled task on a remote machine.  I got to the point that the script did exactly what I needed when I was interactively running it in a Windows session but had problems when running it as a scheduled task.  The debugging process was cumbersome–make a change, schedule a task to run it, log out of the machine, and wait.  The log back in and repeat the process.&lt;/p&gt;
&lt;p&gt;That got old.&lt;/p&gt;
&lt;p&gt;So I wrote &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110711_tester.zip&#34;&gt;a script  (tester.py)&lt;/a&gt; that calls any other python scripts in the same directory that (1) start with &amp;lsquo;test_&amp;rsquo; and (2) there is not a corresponding file with the same base name and &amp;lsquo;.start&amp;rsquo; extension.  It would launch &amp;lsquo;test_BaBing.py&amp;rsquo; as long as there is not a &amp;lsquo;test_BaBing.start&amp;rsquo; in the same directory.  Tester.py continued to run, looping every 60 seconds, until tester.stop exists.&lt;/p&gt;
&lt;p&gt;This made the process easier because I could work on my local machine, editing the problematic script, saving changes and within 60 seconds it would be launched on the remote machine.  I could view the results, make additional edits, delete the .start file and it would launch again within 60 seconds.&lt;/p&gt;
&lt;p&gt;Within a couple minutes I was able to determine the problem (path related) and fix it.&lt;/p&gt;
&lt;p&gt;Happy programmer.&lt;/p&gt;
&lt;p&gt;&lt;disclaimer&gt;I would recommend using this only while debugging a script–routinely running it could be a security risk since someone could copy a destructive python script into the directory and this would run it.&lt;/disclaimer&gt;&lt;/p&gt;
&lt;p&gt;Download: &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110711_tester.zip&#34;&gt;tester.py&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import sys, string, os
import glob
import datetime, shutil
import time, inspect
import getpass

totalstarttime = datetime.datetime.now()

dateString = datetime.date.today().strftime(&amp;quot;%Y%m%d_&amp;quot;)+datetime.datetime.now().strftime(&amp;quot;%H%M%S&amp;quot;) #datetime.date.today().strftime(&amp;quot;%Y%m%d&amp;quot;)
debugfile = inspect.getfile(inspect.currentframe()).replace(&amp;quot;.py&amp;quot;,&amp;quot;_&amp;quot;+dateString+&amp;quot;_Debug.txt&amp;quot;)
stopfile = inspect.getfile(inspect.currentframe()).replace(&amp;quot;.py&amp;quot;,&amp;quot;.stop&amp;quot;)
newdebugfile = False

codeDir = os.path.dirname(inspect.getfile(inspect.currentframe())).replace(&amp;quot;\&amp;quot;,&amp;quot;/&amp;quot;)

def printit(inText):
    global newdebugfile

    print inText

    if os.path.exists(debugfile):
        if (newdebugfile == False):
            tmpfile = open(debugfile,&amp;quot;w&amp;quot;)
            newdebugfile = True
        else:
            tmpfile = open(debugfile,&amp;quot;a&amp;quot;)
    else:
        tmpfile = open(debugfile,&amp;quot;w&amp;quot;)

    tmpfile.write(inText)
    tmpfile.write(&amp;quot;n&amp;quot;)
    tmpfile.close()
    newdebugfile = True

stopFileExists = False
printit(&amp;quot;Code Directory: &amp;quot;+codeDir)
printit(&amp;quot;Starting at: &amp;quot;+datetime.date.today().strftime(&amp;quot;%Y-%m-%d_&amp;quot;)+datetime.datetime.now().strftime(&amp;quot;%H:%M:%S&amp;quot;))
printit(&amp;quot;Stopfile : &amp;quot;+stopfile+&amp;quot;/n&amp;quot;)
while (stopFileExists == False):
    for iFile in glob.glob(codeDir+&amp;quot;/test_*.py&amp;quot;):

        thisStartfile = iFile.replace(&amp;quot;.py&amp;quot;,&amp;quot;.start&amp;quot;)

        if not (os.path.exists(thisStartfile)):
            printit (&amp;quot;Launching: &amp;quot;+iFile)
            iTmpfile = open(thisStartfile,&amp;quot;w&amp;quot;)
            iTmpfile.write(&amp;quot;started&amp;quot;)
            iTmpfile.close()
            os.system(&amp;quot;Start &amp;quot;+iFile)

    if (os.path.exists(stopfile)):
        stopFileExists = True
    else:
        time.sleep(60)

    printit(&amp;quot;nEnd of Loop: &amp;quot;+datetime.date.today().strftime(&amp;quot;%Y-%m-%d_&amp;quot;)+datetime.datetime.now().strftime(&amp;quot;%H:%M:%S&amp;quot;)+&amp;quot;n&amp;quot;)    

printit(&amp;quot;Done!&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;&lt;div id=&#34;geo-post-583&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Checking to see if a Field Index Exists Using Arcpy (ArGIS 10.0) redux</title>
      <link>https://maprantala.com/2011/07/05/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10.0-redux/</link>
      <pubDate>Tue, 05 Jul 2011 12:53:34 -0500</pubDate>
      <guid>https://maprantala.com/2011/07/05/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10.0-redux/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve previously posted python code to check if a field index exists for both &lt;a href=&#34;https://maprantala.com/2011/01/27/checking-to-see-if-a-field-index-exists-using-python/&#34;&gt;ArcGIs 9.3&lt;/a&gt; and &lt;a href=&#34;https://maprantala.com/2011/02/21/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10-0/&#34;&gt;ArcGIS 10.0&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Recently I have been working on a process that was using this code but it was not working because it looks for an index with a specific name.  It was not working in this case because the name of the indexes was getting incremented as they were being created.  For example, I was building an index on the table C5ST, field RelateId ([C5IX].[Relateid]) named I_C5IX_RelateId.  That worked fine until we switched our process so now we keep multiple versions of some tables, each with a date-based suffix.&lt;/p&gt;
&lt;p&gt;We now have tables name C5St_20110625 and C5St_20110626–the Index-name scheme, however was still creating I_C5IX_RelateId and it worked great on the first one.  But when it created the second one, even on a different table, it was automatically name I_C5IX_RelateId_2 even though the name I_C5IX_RelateId was used when trying to create the index.&lt;/p&gt;
&lt;p&gt;Before generating relates, our code checks to see if the key fields are indexed, and if they are not, builds  an index.  Because of the naming situation, multiple, duplicate indexes were being created.  Probably not too harmful but it is a little messy.&lt;/p&gt;
&lt;p&gt;So I re-wrote the code so that you pass the function the table name and field name that you want to check and it checks to see if there is an index existing for that field and return a Boolean.  The one little wrinkle I put in is to account for indexes that span multiple fields–the &#39; if (iIndex.fields[0].Name.upper() == fieldname.upper()):&#39; statement is checking the index to see if it is on a single field or multiple fields.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;def fieldHasIndex(tablename,fieldname):&lt;br&gt;
if not arcpy.Exists(tablename):&lt;br&gt;
return False&lt;/p&gt;
&lt;p&gt;tabledescription = arcpy.Describe(tablename)&lt;/p&gt;
&lt;p&gt;for iIndex in tabledescription.indexes:&lt;br&gt;
if (len(iIndex.fields)==1):&lt;br&gt;
if (iIndex.fields[0].Name.upper() == fieldname.upper()):&lt;br&gt;
return True&lt;/p&gt;
&lt;p&gt;return False&lt;/p&gt;
&lt;/blockquote&gt;
&lt;div id=&#34;geo-post-581&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Feature classes and Tables with names starting with &#39;nd_&#39;</title>
      <link>https://maprantala.com/2011/05/23/feature-classes-and-tables-with-names-starting-with-nd_/</link>
      <pubDate>Mon, 23 May 2011 15:55:24 -0500</pubDate>
      <guid>https://maprantala.com/2011/05/23/feature-classes-and-tables-with-names-starting-with-nd_/</guid>
      <description>&lt;p&gt;Random luck me to discovering a bug related to feature classes whose names start with &amp;lsquo;nd_&#39;.  It appears that you are allowed to create feature classes starting with &amp;lsquo;nd_&amp;rsquo; but ArcCatalog will not display them.  Further research shows this behavior also occurs for table and for ArcSDE (PostGres) geodatabases,  personal geodatabase, and file geodatabases–I am using ArcCatalog 10.0.&lt;/p&gt;
&lt;p&gt;I first noticed something odd was occurring while importing a series of shapefiles into a geodatabases.  After importing 15 shapefiles, I only had thirteen feature classes despite receiving no errors during the process.  The two shapefiles that failed to import were named ND_oil_and_gas.shp and ND_Bendix_Study.shp.  Subsequent attempts to import them individually returned an error &amp;lsquo;Invalid Target Name&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/05/invalidtargetname.png&#34; alt=&#34;Invalid Target Name&#34;&gt;&lt;/p&gt;
&lt;p&gt;I discovered in pgAdmin III (Postgres SDE Geodatabase) that the table existed and there was an entry in sde.sde_layers for the feature class but ArcCatalog refused to show it.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/05/nd_2.png&#34; alt=&#34;nd_&#34;&gt;&lt;/p&gt;
&lt;p&gt;I used some un-supported methods to try to resolve the problem and despite some sweating, I failed to find a way to get ArcCatalog to display these feature classes.  I did, however, at least found a way to delete them–arcpy can detect that the feature classes exists so it is able to delete them.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/05/arcpy_delete.png&#34; alt=&#34;arcpy.delete_management&#34;&gt;&lt;/p&gt;
&lt;p&gt;At least by deleting them, I can prevent leaving &amp;lsquo;invisible&amp;rsquo; feature classes from hanging out in my geodatabase.&lt;/p&gt;
&lt;p&gt;I suspect the problems stems from how ESRI has implemented the &lt;a href=&#34;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002p0000007m000000.htm&#34;&gt;Network dataset table-naming structure&lt;/a&gt; –dirty areas are stored in tables named _nd__dirtyareas and &lt;em&gt;nd__dirtyobjects. Possibly the developer  working on the ArcCatalog GUI ended up suppressing showing feature classes and tables whose names start with &amp;lsquo;nd&lt;/em&gt;&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;And, just for posterity&amp;rsquo;s sake, here is a python code snippet listing the feature classes in a workspace:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy
 
arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;env&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;workspace &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;c:/temp/_nd/F.gdb&amp;#39;&lt;/span&gt;
 
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;env&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;workspace  
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; fc &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFeatureClasses():  
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; fc
 
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Done!&amp;#39;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-564&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Renaming Raster Dataset and arcpy.Exists()</title>
      <link>https://maprantala.com/2011/05/03/renaming-raster-dataset-and-arcpy.exists/</link>
      <pubDate>Tue, 03 May 2011 09:33:48 -0500</pubDate>
      <guid>https://maprantala.com/2011/05/03/renaming-raster-dataset-and-arcpy.exists/</guid>
      <description>&lt;p&gt;Discovered something today. I was working on an arcpy script that copies a raster dataset from a file geodatabase into a Postgres SDE geodatabase and then does some boring routine tasks–building stats, creating a mosaic dataset, adding the raster to the mosaic dataset and making a couple referenced mosaic datasets.&lt;/p&gt;
&lt;p&gt;It sometimes has trouble with the initial step of uploading the raster because of the sheer size of if (1m elevation raster for counties) and it failed today on one. It failed today so I used the ArcCatalog GUI to copy the raster and renamed it.&lt;/p&gt;
&lt;p&gt;I then proceeded to run launch my script. Before each step, I use &lt;a href=&#34;https://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/Exists/000v00000021000000/&#34; target=&#34;_blank&#34;&gt;arcpy.Exists&lt;/a&gt; extensively to check to see if various items exist before I attempt to create them. It was continuously reporting that my raster set did not exist even though I could see it in ArcCatalog.&lt;/p&gt;
&lt;p&gt;Finally, I realized that I needed to close ArcCatalog before arcpy recognized the fact I had renamed something. To note, I was running arcpy from a separate PythonWin window, not from the ArcCatalog session I had renamed the raster dataset with.&lt;/p&gt;
&lt;p&gt;Once I closed ArcCatalog, arcpy recognized the renaming and life was good.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m also suspicious now about a problem I often have running statistics on my rasters.  The ArcTool reports no errors when I create them but for some reason the raster does not show that it has statistics afterwards.  I normally have multiple ArcApplication sessions open and now suspect that perhaps this problem is due to sessions not letting go of the connection.  Stay tuned for further developments on this.&lt;/p&gt;
&lt;div id=&#34;geo-post-546&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Sorting a Coded-Value Domain Add-In (ArcGIS 10)</title>
      <link>https://maprantala.com/2011/05/03/sorting-a-coded-value-domain-add-in-arcgis-10/</link>
      <pubDate>Tue, 03 May 2011 03:33:01 -0500</pubDate>
      <guid>https://maprantala.com/2011/05/03/sorting-a-coded-value-domain-add-in-arcgis-10/</guid>
      <description>&lt;p&gt;I am working on an data-entry application to edit feature classes that contain several coded-value-domains. The problem with some of the domains, however, is that some entries have been added after the initial creation.  So the first 25 entries are in alphabetical order and there are some stragglers at the end that are in the order they were appended.&lt;/p&gt;
&lt;p&gt;This can be confusing for users–they go to select &amp;lsquo;Milli Vanilli&amp;rsquo; and look between &amp;lsquo;Madonna&amp;rsquo; and &amp;lsquo;Motley Crue&amp;rsquo; but can not find their favorite band there–they have to go to the end of the list to find their selection.&lt;/p&gt;
&lt;p&gt;In the past, I have gone through the tedious process of exporting the domain to a table, sorting the table, removing the domain from the necessary field(s), deleting the domain, re-importing the table back in a new domain and finally re-applying the domain to the necessary field(s). Let&amp;rsquo;s just say I didn&amp;rsquo;t do this until someone asked a few times and I didn&amp;rsquo;t have anything more exciting–like a root canal–I could busy myself with.&lt;/p&gt;
&lt;p&gt;But this new application contains more domains than any of other datasets so it was time to find a better solution. ESRI does have a &lt;a href=&#34;http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Geodatabase/Schema_Creation_and_Management/Sort_a_domain/e826c5a8-9740-4f0b-86b6-d3b834735574.htm&#34;&gt;Domain Sort&lt;/a&gt; Developer Sample.  It, however, did &lt;a href=&#34;http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Geodatabase/Schema_Creation_and_Management/Sort_a_domain/e826c5a8-9740-4f0b-86b6-d3b834735574.htm&#34;&gt;not play nice&lt;/a&gt; with ArcGIS 10.&lt;/p&gt;
&lt;p&gt;So I went ahead and update it from VB 6 to VB.Net/ArcObjects 10.  I made an &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/DomainSorter.esriAddIn&#34;&gt;Add-In&lt;/a&gt; that can be installed by downloading the .esriaddin file and double-clicking on it.  The &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20120321_DomainSort.zip&#34;&gt;source code&lt;/a&gt; is also available.&lt;/p&gt;
&lt;p&gt;This will add an ArcCatalog Toolbar that can be added by going to Customize-Toolbars-Domain Sorter Toolbar.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/04/ds_1.png&#34; alt=&#34;Sort Domain-Add Toolbar&#34;&gt;&lt;/p&gt;
&lt;p&gt;This will add a toolbar with one button.  The button enables whenever you select a geodatabase with at least one coded-value domain.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/04/ds_2.png&#34; alt=&#34;Domain Sorter Button&#34;&gt;&lt;/p&gt;
&lt;p&gt;This brings up a Windows form that lets you sort any domain by either the code or description, ascending or descending.  Once you hit &amp;lsquo;OK&amp;rsquo; it re-sorts your domain.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/04/ds_3.png&#34; alt=&#34;Domain Sorter Dialog&#34;&gt;&lt;/p&gt;
&lt;p&gt;The only problem I have had is that only the owner of a domain is allowed to edit it on an SDE geodatabase.&lt;/p&gt;
&lt;p&gt;But other than that, the button allows you to easily keep your domains sorted.&lt;/p&gt;
&lt;p&gt;&lt;small&gt;&lt;a href=&#34;http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Geodatabase/Schema_Creation_and_Management/Sort_a_domain/e826c5a8-9740-4f0b-86b6-d3b834735574.htm&#34;&gt;http://edndoc.esri.com/arcobjects/9.2/CPP_VB6_VBA_VCPP_Doc/COM_Samples_Docs/Geodatabase/Schema_Creation_and_Management/Sort_a_domain/e826c5a8-9740-4f0b-86b6-d3b834735574.htm&lt;/a&gt;&lt;/small&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-522&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty arcpy: Batch Splitting Polylines to a Specific Length</title>
      <link>https://maprantala.com/2011/05/01/quick-dirty-arcpy-batch-splitting-polylines-to-a-specific-length/</link>
      <pubDate>Sun, 01 May 2011 05:01:50 -0500</pubDate>
      <guid>https://maprantala.com/2011/05/01/quick-dirty-arcpy-batch-splitting-polylines-to-a-specific-length/</guid>
      <description>&lt;p&gt;For some odd reason, I wanted to split all the arcs in a polyline feature class to a specific length–if a specific feature was longer than the target length, it would become two or more separate polyline records.&lt;/p&gt;
&lt;p&gt;Here is the &lt;a href=&#34;https://dl.dropbox.com/u/22241283/NodeDangles/20110429_Polyline%20Dicer.zip&#34; target=&#34;_blank&#34;&gt;bare-bones script&lt;/a&gt; that copies an existing feature class into a new feature class then processes each record, splitting it into multiple records if the polyline is longer than the user-specified tolerance.  Some cautionary notes:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;This is Quick &amp;amp; Dirty code–minimal error catching or documentation.&lt;/li&gt;
&lt;li&gt;I basically tested this against one feature class (the one I wanted to split) once I got it to work, I quit.&lt;/li&gt;
&lt;li&gt;There is some rounding error–features may be a tad bit off (a few ten-thousandths of a unit).&lt;/li&gt;
&lt;li&gt;I did not test against multi-part features.&lt;/li&gt;
&lt;li&gt;The tolerance is the native units of the data–if your data is in meters but you want to split the polylines every mile, enter 1,609.344.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I have included both a toolbox file (.tbx) and python script (.py).  After loading the toolbox, you&amp;rsquo;ll have to change the Source of the script by right-clicking on it, selecting the Source tab, and then navigating to the .py file.&lt;/p&gt;
&lt;p&gt;Here is the code for the Googlebots, but you are better off &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110429_Polyline%20Dicer.zip&#34; target=&#34;_blank&#34;&gt;just downloading&lt;/a&gt; it.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; math

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printit&lt;/span&gt;(inMessage):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inMessage
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(inMessage)

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; len(sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; inFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; outFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; alongDistin &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;]
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; alongDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; float(alongDistin)
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; inFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/temp/asdfasdf.mdb/jkl&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; OutDir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/temp/asdfasdf.mdb&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; outFCName &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;jkl2d&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; outFC &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; OutDir&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;outFCName
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; alongDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1000&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(inFC)):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt;(inFC&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; does exist&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Cancelling, &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;inFC&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; does not exist&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exit(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;distPoint&lt;/span&gt;(p1, p2):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; calc1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; p1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;X &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; p2&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;X
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; calc2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; p1&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Y &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; p2&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Y

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; math&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;sqrt((calc1&lt;span style=&#34;color:#f92672&#34;&gt;**&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;(calc2&lt;span style=&#34;color:#f92672&#34;&gt;**&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;))

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;midpoint&lt;/span&gt;(prevpoint,nextpoint,targetDist,totalDist):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newX &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; prevpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;X &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; ((nextpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;X &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; prevpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;X) &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (targetDist&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;totalDist))
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newY &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; prevpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Y &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; ((nextpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Y &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; prevpoint&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Y) &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (targetDist&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;totalDist))
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Point(newX, newY)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;splitShape&lt;/span&gt;(feat,splitDist):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# Count the number of points in the current multipart feature&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; partcount &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; feat&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;partCount
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; partnum &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# Enter while loop for each part in the feature (if a singlepart feature&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# this will occur only once)&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Array()

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;while&lt;/span&gt; partnum &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; partcount:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# Print the part number&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#print &amp;#34;Part &amp;#34; + str(partnum) + &amp;#34;:&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; part &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; feat&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;getPart(partnum)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#print part.count&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; totalDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; pnt &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; part&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;next()
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; pntcount &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; prevpoint &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; None
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; shapelist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; []

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# Enter while loop for each vertex&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;while&lt;/span&gt; pnt:

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (prevpoint &lt;span style=&#34;color:#f92672&#34;&gt;is&lt;/span&gt; None):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; thisDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; distPoint(prevpoint,pnt)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; maxAdditionalDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; splitDist &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; totalDist

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; thisDist, totalDist, maxAdditionalDist

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (totalDist&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;thisDist)&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; splitDist:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;while&lt;/span&gt;(totalDist&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;thisDist) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; splitDist:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; maxAdditionalDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; splitDist &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; totalDist
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#print thisDist, totalDist, maxAdditionalDist&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newpoint &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; midpoint(prevpoint,pnt,maxAdditionalDist,thisDist)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;add(newpoint)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; shapelist&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(lineArray)

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Array()
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;add(newpoint)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; prevpoint &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; newpoint
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; thisDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; distPoint(prevpoint,pnt)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; totalDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;add(pnt)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; totalDist&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;thisDist
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; totalDist&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;thisDist
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;add(pnt)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#shapelist.append(lineArray)&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;add(pnt)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; totalDist &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; prevpoint &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; pnt&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; pntcount &lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; pnt &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; part&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;next()

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;# If pnt is null, either the part is finished or there is an&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&amp;amp;nbsp;&amp;amp;nbsp; interior ring&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; pnt:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; pnt &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; part&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;next()
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; pnt:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Interior Ring:&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; partnum &lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (lineArray&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;count &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; shapelist&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;append(lineArray)

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; shapelist

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(outFC):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Delete_management(outFC)

arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Copy_management(inFC,outFC)

&lt;span style=&#34;color:#75715e&#34;&gt;#origDesc = arcpy.Describe(inFC)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#sR = origDesc.spatialReference&lt;/span&gt;

&lt;span style=&#34;color:#75715e&#34;&gt;#revDesc = arcpy.Describe(outFC)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#revDesc.ShapeFieldName&lt;/span&gt;

deleterows &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;UpdateCursor(outFC)
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iDRow &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; deleterows:&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; deleterows&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;deleteRow(iDRow)

&lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; iDRow
&lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; deleterows

inputRows &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SearchCursor(inFC)
outputRows &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;InsertCursor(outFC)
fields &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(inFC)

numRecords &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; int(arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;GetCount_management(inFC)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;getOutput(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;))
OnePercentThreshold &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; numRecords &lt;span style=&#34;color:#f92672&#34;&gt;//&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;100&lt;/span&gt;

printit(numRecords)

iCounter &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;
iCounter2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iInRow &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; inputRows:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; inGeom &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; iInRow&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;shape
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; iCounter&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; iCounter2&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iCounter2 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; (OnePercentThreshold&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;)):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Processing Record &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(iCounter) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; of &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; str(numRecords))
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; iCounter2&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (inGeom&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;length &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; alongDist):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; shapeList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; splitShape(iInRow&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;shape,alongDist)

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; itmp &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; shapeList:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newRow &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; outputRows&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;newRow()
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; ifield &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; fields:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (ifield&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;editable):
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newRow&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;setValue(ifield&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name,iInRow&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;getValue(ifield&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name))
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; newRow&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;shape &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; itmp
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; outputRows&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;insertRow(newRow)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; outputRows&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;insertRow(iInRow)

&lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; inputRows
&lt;span style=&#34;color:#66d9ef&#34;&gt;del&lt;/span&gt; outputRows

printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Done!&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-528&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Change Detector arcpy Script</title>
      <link>https://maprantala.com/2011/04/08/change-detector-arcpy-script/</link>
      <pubDate>Fri, 08 Apr 2011 10:48:59 -0500</pubDate>
      <guid>https://maprantala.com/2011/04/08/change-detector-arcpy-script/</guid>
      <description>&lt;p&gt;During a process I was working on, I needed to compare a feature class before and after some edits.  I did not quickly find anything in ArcToolbox but searching &lt;a href=&#34;https://resources.arcgis.com/&#34; target=&#34;_blank&#34;&gt;ArcResources&lt;/a&gt; led me to &lt;a href=&#34;https://resources.arcgis.com/gallery/file/Geoprocessing-Model-and-Script-Tool-Gallery/details?entryID=351BEE10-1422-2418-8815-82074A3E6B6C&#34; target=&#34;_blank&#34;&gt;Change Detector script by Bruce Harold&lt;/a&gt;.  After making a couple of tweaks–for some reason in one of my feature classes, the Shape field had an upper case &amp;lsquo;S&amp;rsquo; and in the other it was a lower case &amp;rsquo;s&#39;.  I also discovered that it needs to export to the same format (personal geodatabase, file geodatabase, shapefile) as the source data (or at least one that uses the same field name deliminator).&lt;/p&gt;
&lt;p&gt;After minor adjustments, though, it worked like a charm.  I&amp;rsquo;ll be submitting the changes I made to Bruce and let him incorporate the changes into the official code.&lt;/p&gt;
&lt;p&gt;FOLLOW-UP: Mr. Harold quickly responded to my email &amp;amp; made the change (although I haven&amp;rsquo;t checked it). Way to go Bruce!  Thanks for a handy script.&lt;/p&gt;
&lt;div id=&#34;geo-post-508&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcIdeas: Scale-Dependant Settings</title>
      <link>https://maprantala.com/2011/03/25/arcideas-scale-dependant-settings/</link>
      <pubDate>Fri, 25 Mar 2011 11:29:36 -0500</pubDate>
      <guid>https://maprantala.com/2011/03/25/arcideas-scale-dependant-settings/</guid>
      <description>&lt;p&gt;Someone mentioned an idea on ArcIdeas for making various display settings on a feature classes scale-dependent.  Right now some of that can be accomplished by loading a feature classes multiple times, adjusting the settings, and setting the visible range.  Working more and more in ArcGIS Server, I can see the value of increased scale-dependent settings.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m not sure how rapidly ESRI takes &amp;lsquo;Ideas&amp;rsquo; into consideration but if you feel like it would benefit you, why not promote this idea: &lt;a href=&#34;https://ideas.arcgis.com/ideaView?id=087300000008IPaAAM&#34; target=&#34;_blank&#34;&gt;Scale Range, SQL Query and Symbology Rendering in ArcMap&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Have a good weekend, all!&lt;/p&gt;
&lt;div id=&#34;geo-post-501&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Quick &amp; Dirty arcpy: Field Listings</title>
      <link>https://maprantala.com/2011/03/17/quick-dirty-arcpy-field-listings/</link>
      <pubDate>Thu, 17 Mar 2011 17:03:39 -0500</pubDate>
      <guid>https://maprantala.com/2011/03/17/quick-dirty-arcpy-field-listings/</guid>
      <description>&lt;p&gt;I have to often get a table structure for a feature class or table into either a spreadsheet or word processing document.  There might be an easy way to do this in ArcGIS 10 but I haven&amp;rsquo;t found it.  So, as is my nature, I decided to roll my own.&lt;/p&gt;
&lt;p&gt;This is a &lt;a href=&#34;https://dl.dropbox.com/u/22241283/NodeDangles/20110316_ListFieldCounts-arcpy.zip&#34; target=&#34;_blank&#34;&gt;bare-bones script&lt;/a&gt; that iterates through the fields, printing the field name, type, width, and precision.  There are three optional features to it:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;You can choose to have it list the domain, if there is one, on each field.&lt;/li&gt;
&lt;li&gt;You can have it write to a text file (otherwise you can just copy &amp;amp; paste the results from the results window).&lt;/li&gt;
&lt;li&gt;You can have it count the number of populated records.  This can take a long time if working with a large dataset.  Also note that my logic for determining what constitutes being populated may not be what you need but the structure is there.  I also do not account for all field types, if the field is of a type I have not account for, the code will return -999.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;To use the script from ArcToolbox, you need to pass it four parameters, their Names, type, whether they are input or output, and whether they are required or optional are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;featureclass, Table, Input, Required&lt;/li&gt;
&lt;li&gt;includedomainstring, Boolean, Input, Required (controls whether or not domains are exported)&lt;/li&gt;
&lt;li&gt;doCountsRespone, Boolean, Input, Required (controls whether or not you want to get the number of populated records.  (Your definition of populated may vary from my code)&lt;/li&gt;
&lt;li&gt;outputFile, File, Output, Optional (optional output file to write)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Here is the code, but you are better off &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110316_ListFieldCounts-arcpy.zip&#34; target=&#34;_blank&#34;&gt;just downloading&lt;/a&gt; it since I haven&amp;rsquo;t figured out a good way to have WordPress play nicely with python&amp;rsquo;s indenting.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# Name: ListFields-arcpy.py&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Purpose: Lists the fields, their type, width, and precision&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Can either have it export it to a CSV file or copy&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# and paste from the results window.&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# To use, create a tool from the script and add 3 parameters:&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#  1) Table, Input, Required&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#  2) Boolean, Input, Required (controls whether or not domains are exported)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#  3) Boolean, Input, Rekquired (controls whether or not you want to get the number of&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#  Populated records.&amp;amp;nbsp; (Your defintion of populated may vary from my code)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#  4) File, Output, Optional (optional output file to write)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#&lt;/span&gt;

&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt;sys&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt;os

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printit&lt;/span&gt;(inMessage):
 &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inMessage
 arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(inMessage)

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; len(sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;:
 featureclass &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]
 includedomainstring &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]
 doCountsRespone &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;]
 outputFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;]
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
 featureclass &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/temp/before.shp&amp;#34;&lt;/span&gt;
 includedomainstring &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;false&amp;#34;&lt;/span&gt;
 doCountsRespone &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;true&amp;#34;&lt;/span&gt;
 outputFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/temp/before.csv&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (outputFile &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;):
 doOutputFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; False
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
 doOutputFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; True

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (str(doCountsRespone)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;true&amp;#34;&lt;/span&gt;):
 doCounts &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; True
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
 doCounts &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; False

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (str(includedomainstring)&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower() &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;true&amp;#34;&lt;/span&gt;):
 includedomain &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; True
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
 includedomain &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; False

lfields&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(featureclass)

d &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Describe(featureclass)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Dataset: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;baseName)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Type: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dataType)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Path: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;d&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;catalogPath)
printit(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;)

tableheaders &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;name,type,width,precision&amp;#39;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (doCounts &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):
 tableheaders&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,count&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (includedomain &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):
 tableheaders&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,domain&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (doOutputFile):
 tmpfile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; open(outputFile,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;w&amp;#34;&lt;/span&gt;)
 tmpfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(tableheaders)
 tmpfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n&amp;#34;&lt;/span&gt;)

printit (tableheaders)
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; lf &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; lfields:

 pThisline &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;length)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;precision)

 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (doCounts &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):

 rowCount &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;

 &lt;span style=&#34;color:#75715e&#34;&gt;#Note that I do not account for all field types&lt;/span&gt;
 &lt;span style=&#34;color:#75715e&#34;&gt;#Also note that my definition of being populated may vary from yours.&lt;/span&gt;
 &lt;span style=&#34;color:#75715e&#34;&gt;#I am using -999 as a flag to indicate a field type was not successfully&lt;/span&gt;
 &lt;span style=&#34;color:#75715e&#34;&gt;#identified.&lt;/span&gt;
 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Double&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;or&lt;/span&gt; (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Single&amp;#34;&lt;/span&gt;)&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;nbsp; &lt;span style=&#34;color:#f92672&#34;&gt;or&lt;/span&gt; (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Integer&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;or&lt;/span&gt; (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SmallInteger&amp;#34;&lt;/span&gt;):
  queryString &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&amp;#34;&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&amp;#34; &amp;gt; 0&amp;#39;&lt;/span&gt;
  rows &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SearchCursor(featureclass, queryString, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)
 &lt;span style=&#34;color:#66d9ef&#34;&gt;elif&lt;/span&gt; (lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;type &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;String&amp;#34;&lt;/span&gt;):
  queryString &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&amp;#34;&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&amp;#34; &amp;lt;&amp;gt; &amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#39;&amp;#39;&amp;#34;&lt;/span&gt;
  rows &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SearchCursor(featureclass, queryString, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)
 &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
  rowCount &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;999&lt;/span&gt;
  &lt;span style=&#34;color:#75715e&#34;&gt;#rows = arcpy.SearchCursor(featureclass, &amp;#34;&amp;#34;, &amp;#34;&amp;#34;, &amp;#34;&amp;#34;, &amp;#34;&amp;#34;)&lt;/span&gt;

 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (rowCount &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;):
  &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; row &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; rows:
   rowCount&lt;span style=&#34;color:#f92672&#34;&gt;+=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;

 pThisline&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;pThisline&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;str(rowCount)

 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (includedomain &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; True):
  pThisline&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;pThisline&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;,&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain

 printit (pThisline)

 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (doOutputFile):
  tmpfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(pThisline)
  tmpfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (doOutputFile):
 tmpfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;close
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-473&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Updating Access ODBC connections using VBA</title>
      <link>https://maprantala.com/2011/03/16/updating-access-odbc-connections-using-vba/</link>
      <pubDate>Wed, 16 Mar 2011 20:06:59 -0500</pubDate>
      <guid>https://maprantala.com/2011/03/16/updating-access-odbc-connections-using-vba/</guid>
      <description>&lt;p&gt;I don&amp;rsquo;t do much in Access or VBA but sometimes you inherit things that force you, at least temporarily, to go retro.&lt;/p&gt;
&lt;p&gt;We have an Access-based data extraction routine that uses several (21) pass-through queries that use an ODBC connection.  The queries are pulling data from an Oracle database maintained by a different agency that enforces a time-out of passwords every three months.&lt;/p&gt;
&lt;p&gt;So every three months I have to go through the ODBC connections for these queries and change the password.  And before you chastise me for storing the password in the VBA code, I can only say &amp;lsquo;you&amp;rsquo;re right&amp;rsquo; but that&amp;rsquo;s the way it is done–not ideal but gets the job done and we&amp;rsquo;re not dealing with overly sensitive data.&lt;/p&gt;
&lt;p&gt;Well, my three-month deadline was approaching and I figured I would simplify the process which I found error-prone.&lt;/p&gt;
&lt;p&gt;Some searching and object model diagramming scouring and I came up with this barebones solution, of course, your connection string may vary.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Public Sub UpdateConnectStrings()

Dim obj As AccessObject
Dim dbs As Object
Set dbs = Application.CurrentData

Dim i As Integer

Dim newConnectionString As String
newConnectionString = &amp;quot;ODBC;DRIVER={Microsoft ODBC for Oracle};SERVER=vader;UID=luke;PWD=iMufathr;&amp;quot;

Dim comparisionConnectionString As String
comparisionConnectionString = &amp;quot;ODBC;Driver&amp;quot;

For Each obj In dbs.AllQueries

If (obj.Type = acQuery) Then
  For i = 0 To CurrentDb.QueryDefs.Count - 1
    If (CurrentDb.QueryDefs(i).Name = obj.Name) Then
      If (Left(CurrentDb.QueryDefs(i).Connect, Len(comparisionConnectionString)) = comparisionConnectionString) Then
        CurrentDb.QueryDefs(i).Connect = newConnectionString
      End If
    End If
  Next i
End If

Next obj
End Sub


&lt;/code&gt;&lt;/pre&gt;&lt;div id=&#34;geo-post-456&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Using arcpy to List Domains Assigned to Featureclass Fields</title>
      <link>https://maprantala.com/2011/03/14/using-arcpy-to-list-domains-assigned-to-featureclass-fields/</link>
      <pubDate>Mon, 14 Mar 2011 18:04:36 -0500</pubDate>
      <guid>https://maprantala.com/2011/03/14/using-arcpy-to-list-domains-assigned-to-featureclass-fields/</guid>
      <description>&lt;p&gt;I was making an edit (adding leading &amp;lsquo;0&amp;rsquo;s) to a coded-value domain in an SDE database and realized that my edits were changing the order of the rows of my domain.  Rows were moved to the bottom of the list when they were edited.&lt;/p&gt;
&lt;p&gt;So I went through the process of converting my domain back to a table, made my edits in Access and exported the rows to a .dbf in the order I wanted them.&lt;/p&gt;
&lt;p&gt;I removed the domain from the field I knew it was assigned to but when I tried to delete the domain, I received an error (The domain is used as a default domain).&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/failedtodeletedomain.png&#34; alt=&#34;The domain is used as a default domain.&#34;&gt;&lt;/p&gt;
&lt;p&gt;The Google Machine led me to an &lt;a href=&#34;http://forums.esri.com/Thread.asp?c=93&amp;f=985&amp;t=303616&#34; target=&#34;_blank&#34;&gt;ArcForums post&lt;/a&gt; by  with some python code for listing all the fields with a domain.&lt;/p&gt;
&lt;p&gt;I tweaked the original a bit, first because it was only examining feature classes in a feature dataset, not stand-alone feature datasets.  And secondly, I updated it to use arcpy.  I posted both the &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110314_ListDomains-9_3.zip&#34; target=&#34;_blank&#34;&gt;9.3 version&lt;/a&gt; and the &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110314_ListDomains-10.zip&#34; target=&#34;_blank&#34;&gt;10.0 version&lt;/a&gt;, but here is a quick look.  The key addition is the &amp;ldquo;listfc(&#39;&#39;)&amp;rdquo; line that is the first line of the def listds() module.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy

min_workspace &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;r&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:\Users\mranter\AppData\Roaming\ESRI\Desktop10.0\ArcCatalog\min.minstaff.sde&amp;#34;&lt;/span&gt;

infgdb&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;(min_workspace)
arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;env&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;workspace &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; infgdb

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;listfc&lt;/span&gt;(inDataset):
   featureclasses &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFeatureClasses(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,inDataset)
   &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; f &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; featureclasses:
      &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;feature class: &amp;#34;&lt;/span&gt;,f

lfields&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListFields(f)

&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; lf &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; lfields:
   &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;:
      &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;      domain&amp;#34;&lt;/span&gt;,f, lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;name, lf&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;domain

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;listds&lt;/span&gt;():
   listfc(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)

   datasets&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ListDatasets (&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)
   &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; d &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; datasets:
      &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;  dataset: &amp;#34;&lt;/span&gt;,d

listfc(d)
listds()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-440&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Revoking Public Permissions in PostgreSQL ArcSDE</title>
      <link>https://maprantala.com/2011/03/11/revoking-public-permissions-in-postgresql-arcsde/</link>
      <pubDate>Fri, 11 Mar 2011 11:11:48 -0600</pubDate>
      <guid>https://maprantala.com/2011/03/11/revoking-public-permissions-in-postgresql-arcsde/</guid>
      <description>&lt;p&gt;While banging my head on how to grant access to a &lt;a href=&#34;https://maprantala.com/2011/03/09/referenced-mosaic-datasets-permissions-on-sde/&#34;&gt;referenced mosaic dataset&lt;/a&gt; , I did something out of frustration that I normally would not do–I granted &amp;lsquo;public&amp;rsquo; access to some data.&lt;/p&gt;
&lt;p&gt;Then, after figuring out the problem, I went to revoke public access using ArcCatalog and received this error message:&lt;/p&gt;
&lt;p&gt;Error 999999: Error executing function.&lt;/p&gt;
&lt;p&gt;The Object being referenced does not exist [ERROR:  role &amp;lsquo;public&amp;rsquo; does not exist::SQL state: 42704]&lt;br&gt;
Failed to execute (ChangePrivileges).&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/revokepublic.jpg&#34; alt=&#34;Revoke Public Access in ArcCatalog&#34;&gt;&lt;/p&gt;
&lt;p&gt;I actually expected that would occur–ArcSDE isn&amp;rsquo;t aware of PostgreSQL&amp;rsquo;s public account.&lt;/p&gt;
&lt;p&gt;The solution was to go into pgAdmin II and revoke the privileges there.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/revokepgadminiii.jpg&#34; alt=&#34;Revoke public access in PGadminIII&#34;&#34;&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-428&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Referenced Mosaic Datasets Permissions on SDE</title>
      <link>https://maprantala.com/2011/03/09/referenced-mosaic-datasets-permissions-on-sde/</link>
      <pubDate>Wed, 09 Mar 2011 09:08:27 -0600</pubDate>
      <guid>https://maprantala.com/2011/03/09/referenced-mosaic-datasets-permissions-on-sde/</guid>
      <description>&lt;p&gt;While I&amp;rsquo;m enjoying the functionality of the new &lt;a href=&#34;https://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//00170000008p000000.htm&#34; target=&#34;_blank&#34;&gt;Referenced Mosaic Dataset&lt;/a&gt; that have been introduced in ArcGIS10, something that I stumbled over recently was administering the privileges to a referenced mosaic dataset.&lt;/p&gt;
&lt;p&gt;A referenced mosaic dataset is a raster datatype that uses a mosaic dataset as a base.  For example, we loaded a series of DEMs into a mosaic dataset and then created a referenced mosaic dataset that does the meters to feet conversion for us.  This saved us from having to process each DEM before loading it.  We also created a referenced mosaic dataset hillshade from the original meter data.&lt;/p&gt;
&lt;p&gt;The problem I came across, and this was more my oversight than anything, but I had a heck of a time trying to grant privileges to the referenced mosaic dataset.  The solution was actually very simple–I needed to also grant access to the mosaic dataset that was being used as the base.&lt;/p&gt;
&lt;p&gt;That makes some sense, you should not be able to grant access to a dataset (the referenced mosaic dataset) that would inadvertently be exposing data (the base mosaic dataset) that a user does not have access to.  This, however, conflicts a bit in that the permissions on individual rasters that make up a mosaic raster dataset are ignored.&lt;/p&gt;
&lt;div id=&#34;geo-post-424&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcMap Field Calculator: Calculating Geometry using arcpy</title>
      <link>https://maprantala.com/2011/03/08/arcmap-field-calculator-calculating-geometry-using-arcpy/</link>
      <pubDate>Tue, 08 Mar 2011 09:30:40 -0600</pubDate>
      <guid>https://maprantala.com/2011/03/08/arcmap-field-calculator-calculating-geometry-using-arcpy/</guid>
      <description>&lt;p&gt;One of the things I had not gotten around to doing in ArcGIS 10 was figure out how to directly manipulate the geometry of a record using the &lt;a href=&#34;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//005s00000025000000.htm&#34; target=&#34;_blank&#34;&gt;Field Calculator&lt;/a&gt;.  When I stumbled upon a bug in the way the &lt;a href=&#34;https://maprantala.com/2011/03/07/extract-values-to-points-spatial-analyst-bug/&#34; target=&#34;_blank&#34;&gt;Extract Values to Points&lt;/a&gt; tool handles Null geometries, I figured it was time to figure it out.  Setting the X, Y to 0,0 was sufficient for my needs.&lt;/p&gt;
&lt;p&gt;I set the Parser to Python and the formula was simple once I figured out the syntax:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;pPoint &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Point(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;,&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/origin.jpg&#34; alt=&#34;Use Field Calculator to Calculate Geometry&#34;&gt;&lt;/p&gt;
&lt;p&gt;Then, to extend my knowledge, I wanted to see how to calculate the geometry based off of two fields (X and Y).   The only real trick is knowing the bracket field names using exclamation points instead of brackets:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Point(&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;X&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;,&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;Y&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;!&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/fields.jpg&#34; alt=&#34;Using Field Calculating to Calculate Geometry Using Attributes&#34;&gt;&lt;/p&gt;
&lt;p&gt;So turns out everything it pretty easy and straight-forward.  Whew!&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Extract Values to Points (Spatial Analyst) Bug</title>
      <link>https://maprantala.com/2011/03/07/extract-values-to-points-spatial-analyst-bug/</link>
      <pubDate>Mon, 07 Mar 2011 08:37:33 -0600</pubDate>
      <guid>https://maprantala.com/2011/03/07/extract-values-to-points-spatial-analyst-bug/</guid>
      <description>&lt;p&gt;One of the Spatial Analyst tools we often use in ArcGIS is the &lt;a href=&#34;https://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//009z0000002t000000.htm&#34; target=&#34;_blank&#34;&gt;Extract Values to Points&lt;/a&gt; tool.  This allows us to take a point file (well locations in our case) and attach a value (elevations) from a raster image (a DEM) to each point.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/extractvaluestopoints.jpg&#34; alt=&#34;Extract Values To Points&#34;&gt;&lt;/p&gt;
&lt;p&gt;Today I was running it for the first time against an Image Service we recently published and I received a warning message,&amp;lsquo;WARNING 000957: Skipping feature(s) because of NULL or EMPTY geometry&amp;rsquo;.  But the script seemed to run and the final results said &amp;lsquo;Succeeded&amp;rsquo; so I thought it was probably fine.  But as I double-checked, I realized the results were wonky.&lt;/p&gt;
&lt;p&gt;Turns out that I had two records with Null geometry in my point file of 397 records.  These two records threw the above error but actually had a value in the [Rastervalu] field.  Turns out all 397 records had values.  These two records were consecutive–let&amp;rsquo;s say the 100th and 101st records in my shapefile.  What happened is record 100 got the value for record 102, record 101 get the value for 103, record 102 (which has valid geometry) had the value for 104.  This pattern, each record having the value for the record 2 place after it, continued until record 396 which had the value for record 397.  Record 397 also had the value for 397.  So the final three records all had the value for the final record.&lt;/p&gt;
&lt;p&gt;What I would have expected would be for the two records with Null Geometry to have null values in the [Rastervalu] field and the rest of the records to have the correct values.  Despite the warning, it is very misleading for all the records to end up with a value.&lt;/p&gt;
&lt;p&gt;I have a simplified example below.  I made a point shapefile with four records.  The first, third, and fourth  records have valid geometries; the second has Null geometry.  The second record ends up with the value for the third record.  The third record, has the value for the fourth.  The fourth record being the last record, ends up with the last valid value, which was its own.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/results.jpg&#34; alt=&#34;Test Results&#34;&gt;&lt;/p&gt;
&lt;p&gt;The results that I would have hoped for would be for the third record to have a Null value.&lt;/p&gt;
&lt;p&gt;The way I envision what is occurring behind the scenes is this:  the process makes a list (more of a stack in programming terms) of result values as it processed the points but just assumes that every record will return a value so it does not track which value goes with which shape.&lt;/p&gt;
&lt;p&gt;When it reached the two null geometries, it threw an error but continued on.  It did not add a value for these records to the stack of values–when it comes across records with valid geometry but do not intersect the raster it adds a psuedo-null value of (-9999) to the stack.  After it processed all the records it had 395 values in the stack.  It then went, one-by-one through the stack and populated the records in the output shapefile, the first record got the first value in the stack, the second record got the second value, the 100th record got the 100th value (which came from the location of the 102nd record) and so on.  At the end, the final two records received the last valid value.&lt;/p&gt;
&lt;p&gt;This final behavior–using the last valid value–corresponds a bit to a behavior we&amp;rsquo;ve seen with ArcObjects in general.  When iterating through a table, if a field is Null for a specific row, the value from the last non-Null value for that field is often returned.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m in the process of submitting a bug to ESRI.  I&amp;rsquo;m not sure if this existed prior to ArcGIS 10.0 (I&amp;rsquo;m guessing it did) or if it occurs in other processes (I&amp;rsquo;m guessing it does).  I did find out that the &amp;lsquo;&lt;a href=&#34;https://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//009z0000002s000000.htm&#34; target=&#34;_blank&#34;&gt;Extract Multi Values to Points&lt;/a&gt;&amp;rsquo; works as expected.  I&amp;rsquo;m guessing it is because unlike the &amp;lsquo;Extract Values to Points&amp;rsquo; which creates a new shapefile, this tool appends fields to the existing shapefile and presumably processes records one-by-one without putting the results in a virtual stack.  The &amp;lsquo;Extract Multi Values to Points&amp;rsquo; tool also does not throw any warnings.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/03/same.jpg&#34; alt=&#34;Extract Multi Values to Points&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Instantiating Add-In Objects at Load Time</title>
      <link>https://maprantala.com/2011/03/02/instantiating-add-in-objects-at-load-time/</link>
      <pubDate>Wed, 02 Mar 2011 15:18:14 -0600</pubDate>
      <guid>https://maprantala.com/2011/03/02/instantiating-add-in-objects-at-load-time/</guid>
      <description>&lt;p&gt;In migrating a toolbar consisting of a button and a couple of tools for use in ArcMap 10, I decided to take advantage of the ease of deployment enabled by add-ins which was introduced in 10.0.  So far, I&amp;rsquo;m loving the functionality.&lt;/p&gt;
&lt;p&gt;One thing, however, that I have to figure out is that the controls are not instantiated until they are clicked on.  One of the results is that the controls, by default, are enabled.  This is not the functionality I wanted.&lt;/p&gt;
&lt;p&gt;I found the solution in ESRI&amp;rsquo;s topic, &lt;a href=&#34;https://help.arcgis.com/en/sdk/10.0/arcobjects_net/conceptualhelp/index.html#/Advanced_add_in_concepts/0001000004n7000000/&#34; target=&#34;_blank&#34;&gt;Advanced add-in concepts (ArcObjects .NET 10 SDK)&lt;/a&gt; in the Delayed loading section:&lt;/p&gt;
&lt;p style=&#34;padding-left:30px;&#34;&gt;
  &#39;&lt;strong&gt;&lt;/strong&gt;By default, the assemblies associated with add-in buttons and tools are not loaded until the corresponding item on a toolbar or menu is clicked by the user. This behavior helps conserve application memory and other resources. Since the enabled state of an add-in button or tool is controlled by the OnUpdate method within code, the button or tool will initially appear enabled. If you need tighter control over the initial enabled state of a button or tool, you need to override the default behavior and force the item to load at startup by setting the onDemand Extensible Markup Language (XML) attribute to false.&#39;
&lt;/p&gt;
&lt;p&gt;The verbiage, &amp;lsquo;setting the onDemand Extensible Markup Language (XML) attribute to false&amp;rsquo; was a bit non-specific to me.  I guessed right, however, that they were referring to the control definiton in the Command section of Config.esriaddinx.  In the example below, I set the onDemand attribute to false by adding the  &amp;ldquo;onDemand=&amp;lsquo;false&amp;rsquo;&amp;rdquo; tag and the control did, in fact, get instantiated at load time, giving me the ability to disable it.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;Tool id=&amp;quot;MGS_QDIAddin_QDIAddTool&amp;quot; class=&amp;quot;QDIAddTool&amp;quot; message=&amp;quot;QDI Add New Location.&amp;quot; caption=&amp;quot;QDI Add Tool&amp;quot; tip=&amp;quot;QDI Add Tool.&amp;quot; category=&amp;quot;QDI Add-In Controls&amp;quot; image=&amp;quot;ImagesQDIAddTool.png&amp;quot; onDemand=&amp;quot;false&amp;quot;&amp;gt;

&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Loading Tiled, Same-Name Data in Batch Mode.</title>
      <link>https://maprantala.com/2011/02/28/loading-tiled-same-name-data-in-batch-mode./</link>
      <pubDate>Mon, 28 Feb 2011 12:30:43 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/28/loading-tiled-same-name-data-in-batch-mode./</guid>
      <description>&lt;p&gt;I have been loading existing raster data into a geodatabase to be included in a new Mosaic Dataset–a very cool and useful addition to ArcGIS 10. The most time-consuming part of the process for the human (at least this human) has been getting the names of the rasters right.&lt;/p&gt;
&lt;p&gt;Our existing data is organized by tiles with the directory name representing the tile name and then the data within each tile directory having the same name.&lt;/p&gt;
&lt;p&gt;For example:&lt;br&gt;
C:\GIS_dataAdamsparcels.shp&lt;br&gt;
C:\GIS_dataBuchetteparcels.shp&lt;/p&gt;
&lt;p&gt;This makes batch loading the data less efficient because I end up having to rename the data or else end up with a series of feature classes named parcels, parcels_2, parcels_n.&lt;/p&gt;
&lt;p&gt;So I hacked out a quick script that takes an input raster and figures out the final name I want it to have based of the directory name.&lt;/p&gt;
&lt;p&gt;First, I used the Copy Raster (In ArcToolbox: Data Management-Raster-Raster Dataset-Copy Raster) and copied on sample to my geodatabase.&lt;/p&gt;
&lt;p&gt;Then, I went to the Results Tab (Select Geoprocessing from the Menubar, Geoprocessing-Results) and right-clicked on the Copy Raster result and selected &amp;lsquo;Copy as Python Snippet&amp;rsquo;.&lt;/p&gt;
&lt;p&gt;I then created a new python script and pasted the one line.&lt;/p&gt;
&lt;p&gt;I added some imports, accepted a parameter, some string manipulation, and some result outputs and I had a quick &amp;amp; easy script. In added the script in ArcToolbox and now I can right-click on it and run it in Batch mode. I do a quick search in Windows Explorer to get all the rasters I want to run it on and select &amp;amp; drag them to my ArcToolbox Batch Dialog.&lt;/p&gt;
&lt;p&gt;Actual code can be downloaded &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110228_load_lidar_data.zip&#34; target=&#34;_blank&#34;&gt;HERE&lt;/a&gt; and you don&amp;rsquo;t need to worry about WordPress messing up the spacing.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; arcpy
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; sys

inRaster &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;argv[&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;] 
basedir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;basename(os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;dirname(inRaster))&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower()
outRaster &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Database Connections/mgs_lidar.lidar.sde/mgs_lidar.lidar.&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;basedir

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;printit&lt;/span&gt;(inMessage):
    &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inMessage
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddMessage(inMessage)
    
&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(outRaster)):
    printit (&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Importing: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;basedir)
    arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;CopyRaster_management(inRaster,outRaster,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;#&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;#&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;#&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NONE&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NONE&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;#&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
    printit (&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Skipping: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;basedir&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; because it already exists!&amp;#34;&lt;/span&gt;)

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-385&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ESRI Font Samples.pdf (application/pdf Object)</title>
      <link>https://maprantala.com/2011/02/23/esri-font-samples.pdf-application/pdf-object/</link>
      <pubDate>Wed, 23 Feb 2011 08:12:59 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/23/esri-font-samples.pdf-application/pdf-object/</guid>
      <description>&lt;p&gt;Whenever I want to skim through ESRI&amp;rsquo;s fonts to find some symbology I need for a specific purpose, I go through some laborious process to skim the fonts searching for an adequate symbol.&lt;/p&gt;
&lt;p&gt;However, in the &lt;a href=&#34;http://blogs.esri.com/Support/blogs/mappingcenter/archive/2010/04/05/About-Fonts-in-ArcMap-Symbols.aspx&#34; target=&#34;_blank&#34;&gt;ESRI Mapping Center blog post&lt;/a&gt;, user &lt;a href=&#34;https://blogs.esri.com/Support/user/Profile.aspx?UserID=24410&#34; target=&#34;_blank&#34;&gt;use2b311&lt;/a&gt; post a link to a pre-made pdf showing &lt;a href=&#34;https://maprantala.com/wp-content/uploads/2011/02/ESRI-Font-Samples.pdf&#34;&gt;ESRI Font Samples.pdf (application/pdf Object)&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Back when ESRI use to actually print hard-copy manuals, there were similar diagrams available but either I haven&amp;rsquo;t searched enough of they don&amp;rsquo;t exist in the digital help systems so I was happy to stumble upon this.&lt;/p&gt;
&lt;p&gt;A tangent discovery in checking this out was &lt;a href=&#34;http://www.dropbox.com/features&#34; target=&#34;_blank&#34;&gt;dropbox&lt;/a&gt;, a free (with 2 Gig limit) online file sharing/online backup site–something I&amp;rsquo;ve had a need for but haven&amp;rsquo;t gotten around to researching. I have not tried them but may, just to see how well it works.&lt;/p&gt;
&lt;div id=&#34;geo-post-380&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcGIS Online Basemaps Now Free</title>
      <link>https://maprantala.com/2011/02/22/arcgis-online-basemaps-now-free/</link>
      <pubDate>Tue, 22 Feb 2011 12:57:58 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/22/arcgis-online-basemaps-now-free/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve seen several posts like this &lt;a href=&#34;http://gisandscience.com/2011/02/19/arcgis-online-basemaps-now-freely-available-regardless-of-use/&#34; target=&#34;_blank&#34;&gt;one&lt;/a&gt; that reiterate that ESRI has announced that:&lt;/p&gt;
&lt;p&gt;&amp;lsquo;As of the end of January, ArcGIS Online basemaps published and hosted by Esri are now freely available to all users regardless of commercial, noncommercial, internal, or external use. This means that you no longer have to pay a subscription fee for including ArcGIS Online basemaps in your commercial-use web applications. Basemaps included in this new business model are World Imagery Map, World Street Map, World Topographic Map, USA Topographic Maps, and DeLorme World Basemap. The only restriction is a high-volume transaction limit of 50,000,000 transactions in a 12-month period, which is equivalent to 400,000,000 tile requests per year, or over 1,000,000 per day – a volume that most likely very few users will reach. ‘Read the &lt;a rel=&#34;nofollow&#34; href=&#34;http://autobahn.esri.com/esri/etrack.aspx?DSN=b9ca57b2fbe8cb42458807853387983f6a0f6be5ccdab113&amp;FORMID=cf3c99c960ec478b5ac989cb09fa904c&amp;INTID=ffa8a16a91dafc29096bc3950a167d4d&amp;AUDID=6a40943f05d56964612f9b4af7d9ff52&amp;DECODE=1&amp;URL=http://blogs.esri.com/Support/blogs/arcgisonline/default.aspx&#34; target=&#34;_blank&#34;&gt;&lt;span style=&#34;color:#008100;&#34;&gt;ArcGIS Online blog&lt;/span&gt;&lt;/a&gt; to get the latest news and updates.&amp;rsquo;&#39;&lt;/p&gt;
&lt;p&gt;I was unable to find a copy of the announcement on the ArcGIS Online blog or on &lt;a href=&#34;https://www.esri.com/news/index.html&#34; target=&#34;_blank&#34;&gt;ESRI&amp;rsquo;s news section&lt;/a&gt; although I did receive an email that Charles Convis, &lt;a href=&#34;https://www.conservationgis.org/&#34; target=&#34;_blank&#34;&gt;ESRI Conservation Program Coordinator&lt;/a&gt;, sent to the &lt;a href=&#34;https://www.scgis.org/&#34; target=&#34;_blank&#34;&gt;Society for Conservation GIS&lt;/a&gt; mailing list with the same information so I&amp;rsquo;m guessing it is true. Perhaps ESRI pulled the post hoping to release the information with more of a splash?&lt;/p&gt;
&lt;p&gt;Regardless, I think that this only helps make quick, affordable, professional web application more possible.&lt;/p&gt;
&lt;p&gt;While skimming the ArcGIS Online Blog, I found a &lt;a href=&#34;https://blogs.esri.com/Support/blogs/arcgisonline/archive/2011/02/09/blogging-with-arcgis-online-maps.aspx&#34; target=&#34;_blank&#34;&gt;post about embedding a hosted map&lt;/a&gt; into your blog. Like this one of Arlington, Texas, where Super Bowl XLV was played a couple weeks ago. And, in case you missed it, the now 13-Time World Champions, &lt;a href=&#34;https://www.packers.com/&#34; target=&#34;_blank&#34;&gt;Green Bay Packers&lt;/a&gt;, beat the Pittsburgh Steelers 31-25, winning the team&amp;rsquo;s fourth Super Bowl. ESRI also published this &lt;a href=&#34;https://www.esri.com/news/maps/superbowl/index.html&#34; target=&#34;_blank&#34;&gt;neat application&lt;/a&gt; that spatially shows which team football fans were rooting for.&lt;/p&gt;
&lt;p&gt;Unfortunately, the free WordPress blogging software I am using allows only limited set of embedded frames–arcgis online maps not being one of them. There are wordpress add-ins to allow this but my host, WordPress.com, does not include it so you&amp;rsquo;ll just see a link. Rather disappointing.&lt;/p&gt;
&lt;p&gt;&lt;a style=&#34;color:#0000ff;text-align:left;&#34; href=&#34;http://www.arcgis.com/home/webmap/viewer.html?webmap=4b99c1fb712d4fe694805717df5fadf2&#34; target=&#34;_blank&#34;&gt;View Arlington Map&lt;/a&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-370&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Checking to see if a Field Index Exists Using Arcpy (ArGIS 10.0)</title>
      <link>https://maprantala.com/2011/02/21/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10.0/</link>
      <pubDate>Mon, 21 Feb 2011 09:55:35 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/21/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10.0/</guid>
      <description>&lt;p&gt;Updating some python code from 9.3 that using geoprocessing  to 10.0 using arcpy and the first real object I&amp;rsquo;ve had to change relates to detecting whether or not an index exists on a table.&lt;/p&gt;
&lt;p&gt;I previously &lt;a href=&#34;https://maprantala.com/2011/01/27/checking-to-see-if-a-field-index-exists-using-python/&#34;&gt;posted code&lt;/a&gt; using a 9.3 geoprocessing commands, the core of it being:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;indexList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;listindexes(tablename)
&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iIndex &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; indexList:
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iIndex&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; indexname):
       &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True
&lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;With arcpy, ESRI has gone back to using the &lt;a href=&#34;http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/Describe/000v00000026000000/&#34; target=&#34;_blank&#34;&gt;Describe&lt;/a&gt; methodology.  Way back when GISers use to type most of their commands into their wood-burning computers, the command &amp;lsquo;Describe&amp;rsquo; was used to retrieve information about a coverage, grid, or other data set in our fancy AMLs (or SMLs).  The snippet below shows a function for checking to see if a table has an index with a specified named.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;indexExists&lt;/span&gt;(tablename,indexname):

 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(tablename):
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

 tabledescription &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcpy&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Describe(tablename)

 &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iIndex &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; tabledescription&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;indexes:
  &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iIndex&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; indexname):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True

 &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-364&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Multiple geodatabases and ArcSDE services from one PostgreSQL server</title>
      <link>https://maprantala.com/2011/02/17/multiple-geodatabases-and-arcsde-services-from-one-postgresql-server/</link>
      <pubDate>Thu, 17 Feb 2011 18:22:07 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/17/multiple-geodatabases-and-arcsde-services-from-one-postgresql-server/</guid>
      <description>&lt;p&gt;To better organize our ArcSDE data, we wanted to create multiple geodatabases and multiple ArcSDE services using one PostgreSQL database cluster (a cluster containing 1 machine at this point).  A side question is why can&amp;rsquo;t tables and raster be placed in Feature Datasets?  This wouldn&amp;rsquo;t be an end-all solution for what we want to do but there are some messy consequences of this limitation.&lt;/p&gt;
&lt;p&gt;ESRI has instructions on &lt;a href=&#34;https://help.arcgis.com/EN/ArcGISDesktop/10.0/Help/index.html#//002p00000011000000.htm&#34; target=&#34;_blank&#34;&gt;Setting up multiple geodatabases in one PostgreSQL database cluster on Windows&lt;/a&gt; which was helpful but we repeatedly got an &amp;lsquo;The ArcSDE Repository was unsuccessfully completed.  Would you like to view this error?&amp;rsquo; error during the Repository Setup step, step two of four, of the ArcSDE Post Installation process. The odd thing, however, was that the wise_err.log was blank so I had no clue on why it was failing.  After much Googling and head-banging, I came across a &lt;a href=&#34;http://forums.esri.com/Thread.asp?c=158&amp;f=2290&amp;t=298474#941273&#34; target=&#34;_blank&#34;&gt;post from&lt;/a&gt; &lt;a href=&#34;http://www.linkedin.com/profile/view?id=24468141&amp;authType=name&amp;authToken=VoHW&amp;pvs=pp&amp;trk=ppro_viewmore&#34; target=&#34;_blank&#34;&gt;Kim Doty&lt;/a&gt; on ESRI&amp;rsquo;s forums reporting the same problem but they were able to create a service by just continuing through the process .  Figuring I had nothing to lose, I thought I might as well try to go through the entire ArcSDE Post Installation process and see what happened.  Although I received blank error messages, I was able to successfully create the second ArcSDE instance.&lt;/p&gt;
&lt;p&gt;I will touch on some of the highlights of the process.  In my case, I was creating a database &amp;amp; service with these parameters:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Database name:&lt;img src=&#34;https://maprantala.com/Users/mrantala/AppData/Local/Temp/moz-screenshot-11.png&#34; alt=&#34;&#34;&gt; mgsgdb_lidar&lt;/li&gt;
&lt;li&gt;Service name:  mgs1_sde&lt;/li&gt;
&lt;li&gt;Tablespace folder: D:mgsdb1dmgsgdb_lidar&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Following ESRI&amp;rsquo;s instructions, I first made custom copies of dbinit.sde, dbtune.sde, and giomgr.defs that contain the service name (mgs1_sde) within the file name.  These copies were named dbinit_mgs1_sde.sde, dbtune_mgs1_sde.sde, and giomgr_mgs1_sde.defs.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/files1.jpg&#34; alt=&#34;Custom Files&#34;&gt;&lt;/p&gt;
&lt;p&gt;When I have trouble with the ArcSDE Post Installation, I like to go through the four steps individually so I select a &amp;lsquo;Custom&amp;rsquo; install.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/custom.jpg&#34; alt=&#34;Custom Setup&#34;&gt;&lt;/p&gt;
&lt;p&gt;The four steps making up the ArcSDE Post Installation process are shown on the next dialog.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/steps.jpg&#34; alt=&#34;Individual Steps&#34;&gt;&lt;/p&gt;
&lt;p&gt;I was able to complete the first step, Define SDE User Environment, without any problems.&lt;/p&gt;
&lt;p&gt;Make sure to set your database name, default tablespace, and tablespace folders are distinct from your first installation.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/databaseinfo.jpg&#34; alt=&#34;Database name and workspace&#34;&gt;&lt;/p&gt;
&lt;p&gt;During the second step of the ArcSDE Post Installation process, Repository Setup, make sure to use the custom files you made earlier when you come to the ArcSDE configuratino files dialog.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/customfiles.jpg&#34; alt=&#34;Custom Files&#34;&gt;&lt;/p&gt;
&lt;p&gt;Later in the Repository Setup, make sure to use the correct database name:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/step2-databasename.jpg&#34; alt=&#34;Step2, Set Database Name&#34;&gt;&lt;/p&gt;
&lt;p&gt;This is the first error message I received in the process (still during Repository Setup):&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/viewerror.jpg&#34; alt=&#34;View Error&#34;&gt;&lt;/p&gt;
&lt;p&gt;Clicking &amp;lsquo;Yes&amp;rsquo;, however, shows an empty wise_err.log file:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/emptylog.jpg&#34; alt=&#34;Empty Log&#34;&gt;&lt;/p&gt;
&lt;p&gt;After viewing this, I canceled out of the Repository Setup step.&lt;/p&gt;
&lt;p&gt;Taking a look in pgAdmin III, however, I can see that both my database (mgsgdb_lidar) and tablespace (mgsgdb_lidar) were created:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/step2-inpgadminiii.jpg&#34; alt=&#34;pgAdminIII&#34;&gt;&lt;/p&gt;
&lt;p&gt;I received the same error message during the third step, Authorize ArcSDE, as in the second step:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/step3error.jpg&#34; alt=&#34;Step 3 Error&#34;&gt;&lt;/p&gt;
&lt;p&gt;But running the fourth step, Create ArcSDE Service, resulted in this sweet message:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/success.jpg&#34; alt=&#34;Success&#34;&gt;&lt;/p&gt;
&lt;p&gt;After editing my pg_hba.conf and opening the port in my firewall, the service was created, running, and visible.  So far, it seems to be fully functional and without problems.&lt;/p&gt;
&lt;div id=&#34;geo-post-340&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Walkthrough: Building custom UI elements using add-ins (ArcObjects .NET 10 SDK)</title>
      <link>https://maprantala.com/2011/02/15/walkthrough-building-custom-ui-elements-using-add-ins-arcobjects-.net-10-sdk/</link>
      <pubDate>Tue, 15 Feb 2011 17:05:55 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/15/walkthrough-building-custom-ui-elements-using-add-ins-arcobjects-.net-10-sdk/</guid>
      <description>&lt;p&gt;I was working my way through this ESRI &lt;a href=&#34;http://help.arcgis.com/en/sdk/10.0/arcobjects_net/conceptualhelp/index.html#//0001000001ms000000&#34; target=&#34;_blank&#34;&gt;Walkthrough: Building custom UI elements using add-ins (ArcObjects .NET 10 SDK)&lt;/a&gt;.  And came across a couple minor errors that I had to correct during the process.&lt;/p&gt;
&lt;p&gt;First, while implementing the OnClick() code for ZoomToLayer.vb, Visual Studio gave me a &amp;lsquo;Name ‘ArcMap&amp;rsquo; is not declared.&#39; error.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/arcmapnotdeclared.jpg&#34; alt=&#34;ArcMap Not Declared&#34;&gt;&lt;/p&gt;
&lt;p&gt;In the walk-through, they mention that the ArcMap method of your class.  For me, however, it appeared under the .My method.  Not sure if this is something specific to my set-up or, as I&amp;rsquo;m guessing, something that got changed after the first documentation was created and the final libraries published.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/objectbrowser.jpg&#34; alt=&#34;Object Browser&#34;&gt;&lt;/p&gt;
&lt;p&gt;The fix is just adding  &amp;lsquo;My.&amp;rsquo; to the namespace in this line:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ZoomToActiveLayerInTOC(TryCast(ArcMap.Application.Document, IMxDocument))
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To get this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ZoomToActiveLayerInTOC(TryCast(My.ArcMap.Application.Document, IMxDocument))
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;When I added the code for AddGraphics.vb, I got 8 errors.  There was essentially two errors, repeated four times.  I took a screen shot after fixing the first error pair:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/errorlist.jpg&#34; alt=&#34;Add Graphics Error List&#34;&gt;&lt;/p&gt;
&lt;p&gt;The fixes in this case was also to use the complete name space path.  Examples:&lt;/p&gt;
&lt;p&gt;Change this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(geometry.GeometryType) = esriGeometryType.esriGeometryPoint Then
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;If (geometry.GeometryType) = ESRI.ArcGIS.Geometry.esriGeometryType.esriGeometryPoint Then)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;And change this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;simpleMarkerSymbol.Style = esriSimpleMarkerStyle.esriSMSCircle
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;simpleMarkerSymbol.Style = ESRI.ArcGIS.Display.esriSimpleMarkerStyle.esriSMSCircle
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Overall, the walk-through is very well done, just a couple minor tweaks.  I am now working my way through modifying an existing solution–one that included seven projects–to see if I can create an ArcGIS 10 Add-In.&lt;/p&gt;
&lt;div id=&#34;geo-post-328&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Zipping a File Geodatabase using Python</title>
      <link>https://maprantala.com/2011/02/08/zipping-a-file-geodatabase-using-python/</link>
      <pubDate>Tue, 08 Feb 2011 13:44:34 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/08/zipping-a-file-geodatabase-using-python/</guid>
      <description>&lt;p&gt;Ever since the ever-popular post, &lt;a href=&#34;https://maprantala.com/2010/12/10/zipping-a-shapefile-using-python/&#34;&gt;Zipping a shapefile using python&lt;/a&gt;, came out, people have been asking (one person, yesterday) for a sample of how to zip a file geodatabase using python.&lt;/p&gt;
&lt;p&gt;The key trick, as shown in line 17, is appending the basename of the file geodatabase (&amp;lsquo;nfg.gdb/&amp;rsquo; in my example) in front of each file as you write it to the zipfile.&lt;/p&gt;
&lt;p&gt;UPDATE: WordPress messes with the spacing when I post code, making it difficult to post code that can just be copied &amp;amp; pasted and have work.  So I have posted a the code &lt;a href=&#34;http://dl.dropbox.com/u/22241283/NodeDangles/20110208_Sample_Zip_FileGeodatabase.zip&#34;&gt;HERE&lt;/a&gt; for downloading.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; zipfile
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; glob

infile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;c:/temp/nfg.gdb&amp;#34;&lt;/span&gt;
outfile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;c:/temp/nfg.zip&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;zipFileGeodatabase&lt;/span&gt;(inFileGeodatabase, newZipFN):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exists(inFileGeodatabase)):
      &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

   &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exists(newZipFN)):
      os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;remove(newZipFN)

   zipobj &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; zipfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ZipFile(newZipFN,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;w&amp;#39;&lt;/span&gt;)

   &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; infile &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;glob(inFileGeodatabase&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/*&amp;#34;&lt;/span&gt;):
      zipobj&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(infile, os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;basename(inFileGeodatabase)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;basename(infile), zipfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ZIP_DEFLATED)
      &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; (&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Zipping: &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;infile)

   zipobj&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;close()

   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True

zipFileGeodatabase(infile,outfile)

&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-312&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Using ArcGIS 9.3.1 Desktop to Extract Data From an ArcGIS 10 Server Geodata Service</title>
      <link>https://maprantala.com/2011/02/04/using-arcgis-9.3.1-desktop-to-extract-data-from-an-arcgis-10-server-geodata-service/</link>
      <pubDate>Fri, 04 Feb 2011 18:26:53 -0600</pubDate>
      <guid>https://maprantala.com/2011/02/04/using-arcgis-9.3.1-desktop-to-extract-data-from-an-arcgis-10-server-geodata-service/</guid>
      <description>&lt;p&gt;In building our Enterprise GIS Database, we need to support users with different needs.  Some of our users just need to see the data on a map while others may want to download a copy of the data so they can use it within their own desktop system.&lt;/p&gt;
&lt;p&gt;After doing some exploring, one of the options that looks like it will feel the bulk of our internal needs is to create a &lt;a href=&#34;https://webhelp.esri.com/arcgisdesktop/9.3/index.cfm?TopicName=Types_of_services_in_ArcGIS_Server&amp;anchor=ArcGIS%20Map%20service)&#34; target=&#34;_blank&#34;&gt;Map Service&lt;/a&gt;/&lt;a href=&#34;http://webhelp.esri.com/arcgisdesktop/9.3/index.cfm?TopicName=Types_of_services_in_ArcGIS_Server&amp;anchor=ArcGIS%20Geodata%20service&#34; target=&#34;_blank&#34;&gt;Geodata Service&lt;/a&gt; pair–by creating a Map Service, we can make an easy-to-use visual representation of our data.  Combining that with a paired Geodata Service–a Geodata Service with the same name as the Map Service–we can accommodate those users who want to extract the data to their hard drive.&lt;/p&gt;
&lt;p&gt;A user who has added paired Map &amp;amp; Geodata Services to an ArcMap dataframe can use the Distributed Geodatabase Toolbar to extract data to a local geodatabase.  The Extract Data button is on the far right of the Distributed Geodatabase Toolbar.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/distributedgeodatabasetoolbar.jpg&#34; alt=&#34;Distributed Geodatabase Toolbar&#34;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Unfortunately, my first attempts at testing this did not work.  It would look like it was processing, I would end up with a .mdb or .gdb file on my hard drive but I could not open it.  I would get a &amp;lsquo;Failed to connect to database. This release of the GeoDatabase is eitehr invalid or out of date. [Unknown GeoDatabase release.]  The Microsoft Jet database engine cannot find the input table or query ‘GDB_ReleaseInfo&amp;rsquo;. Make sure it exists and that its name is spelled correctly.&#39; error.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/versionerror.jpg&#34; alt=&#34;Version Error&#34;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;When exporting to an .mdb file, I could open it in Access and see the data.&lt;/p&gt;
&lt;p&gt;Luckily the error is fairly helpful–I was getting an ArcGIS &lt;a href=&#34;https://blogs.esri.com/Dev/blogs/geodatabase/archive/2010/03/15/The-Simplified-Geodatabase-Schema-in-ArcGIS-10.aspx&#34; target=&#34;_blank&#34;&gt;10 Geodatabase&lt;/a&gt; even though I am running ArcGIS 9.3.1 on my desktop.  I was able to open the exported geodatabases using a copy of ArcGIS 10 on another machine.   The reason for the inconsistency is pretty interesting.  Our office is, and for the foreseeable future, running in a mixed-version environment.  We have a mixture of 9.3.1 and 10 desktops, a 9.3.1 ArcSDE server and a 10 ArcGIS Server.  The Extract Tool is a server-side function apparently that creates a version 10 Geodatabase.&lt;/p&gt;
&lt;p&gt;The way to get around this is to extract the data to XML and then import the XML workspace into a geodatabase.  Not sure if that will work for all schemas but it was successful for me.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/02/exportxml.jpg&#34; alt=&#34;Export XML&#34;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;div id=&#34;geo-post-304&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Checking to see if a Field Index Exists Using Python (geoprocessing 9.3).</title>
      <link>https://maprantala.com/2011/01/27/checking-to-see-if-a-field-index-exists-using-python-geoprocessing-9.3./</link>
      <pubDate>Thu, 27 Jan 2011 15:31:48 -0600</pubDate>
      <guid>https://maprantala.com/2011/01/27/checking-to-see-if-a-field-index-exists-using-python-geoprocessing-9.3./</guid>
      <description>&lt;p&gt;NOTE:  I have a &lt;a href=&#34;https://maprantala.com/2011/02/21/checking-to-see-if-a-field-index-exists-using-arcpy-argis-10-0/&#34;&gt;post here&lt;/a&gt; that shows how to check if a field exists using arcpy in ArcGIS 10.0.&lt;/p&gt;
&lt;p&gt;In developing a python script to reload a geodatabase, I wanted to create any necessary indexes.&lt;/p&gt;
&lt;p&gt;No problem creating the index, for example:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddIndex_management(tablename, field, IndexName, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NON_UNIQUE&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NON_ASCENDING&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;But before creating the index, I wanted to verify that it did not exist.  I tried the ever-popular, exists but could not get it to work–either it does not detect indexes or I just never got the fully-qualified name for the index right (ArcSDE using a postgres datastore).&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(mgs_c5ix_fullname)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I finally found this &lt;a href=&#34;http://webhelp.esri.com/arcgiSDEsktop/9.3/index.cfm?TopicName=ListIndexes_method&#34; target=&#34;_blank&#34;&gt;ArcGIS Desktop Help 9.3 – ListIndexes method&lt;/a&gt; from ESRI.  Unfortunately, it doesn&amp;rsquo;t work-it did not like the &amp;lsquo;while&amp;rsquo; loop construction.  I&amp;rsquo;m guessing it worked in 9.2 and despite ESRI&amp;rsquo;s own &lt;a href=&#34;https://webhelp.esri.com/arcgiSDEsktop/9.3/index.cfm?TopicName=Differences_between_geoprocessor_versions&#34; target=&#34;_blank&#34;&gt;warning&lt;/a&gt; about differences in 9.2 &amp;amp; 9.3, they did not update the sample code.&lt;/p&gt;
&lt;p&gt;A key is to make sure you create a 9.3-version geoprocessing object and the following code can be used.  The caveat that I need to include is that the code only checks one table, if the index is on a different table, it will give you a false-negative.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;gp &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcgisscripting&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;create(&lt;span style=&#34;color:#ae81ff&#34;&gt;9.3&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;indexExists&lt;/span&gt;(tablename,indexname):
 &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Exists(tablename):
  &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

 indexList &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;listindexes(tablename)

 &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; iIndex &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; indexList:
  &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (iIndex&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Name &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; indexname):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True

 &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;To call it, just pass the table and indexname you are looking for.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;indexExists(tablename,indexname)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-298&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ArcGIS 9.3.1 to ArcSDE 10 Connection Error</title>
      <link>https://maprantala.com/2011/01/13/arcgis-9.3.1-to-arcsde-10-connection-error/</link>
      <pubDate>Thu, 13 Jan 2011 14:41:58 -0600</pubDate>
      <guid>https://maprantala.com/2011/01/13/arcgis-9.3.1-to-arcsde-10-connection-error/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://maprantala.com/Users/mrantala/AppData/Local/Temp/moz-screenshot-7.png&#34; alt=&#34;&#34;&gt;We finally installed an instance of ArcSDE 10 today.  My first attempt at connecting in ArcCatalog 9.3.1 failed with the following error:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Failed to connect to the specified server.&lt;/p&gt;
&lt;p&gt;This release of the GeoDatabase is either invalid or out of date. [Please run the&lt;/p&gt;
&lt;p&gt;ArcSDE setup utility using the -o install option.]&lt;/p&gt;
&lt;p&gt;DBMS table not found [sde.sde.GDB_Release]&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/01/connecterror2.jpg&#34; alt=&#34;ConnectError2&#34;&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Turns out the solution was simple, this &lt;a href=&#34;https://resources.arcgis.com/content/kbase?fa=articleShow&amp;d=37385&#34; target=&#34;_blank&#34;&gt;article&lt;/a&gt; points out that &lt;a href=&#34;https://resources.arcgis.com/content/patches-and-service-packs?fa=viewPatch&amp;PID=17&amp;MetaID=1620&#34; target=&#34;_blank&#34;&gt;Service pack 2&lt;/a&gt; is required.  After updating my ArcGIS, the problem was solved:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/01/errormessage.jpg&#34; alt=&#34;ErrorMessage&#34;&gt;&lt;/p&gt;
&lt;p&gt;I was the proud, new recipient of a non-misleading error message.  After some minor head-slapping, I realized that &lt;a href=&#34;https://wikis.esri.com/wiki/display/SupportCenter/ArcGIS+10+-+Product+Compatibility+Matrix+for+Clients+and+Servers+of+ArcSDE+technology+in+ArcGIS+Server&#34; target=&#34;_blank&#34;&gt;9.3.1 and older versions of ArcGIS&lt;/a&gt; are not able to connect to ArcSDE 10.  Doh!  My bad–I should have read ESRI&amp;rsquo;s &lt;a href=&#34;https://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#/Compatibility_between_clients_and_geodatabases_in_PostgreSQL_when_using_an_ArcSDE_service/002p000000pw000000/&#34; target=&#34;_blank&#34;&gt;clear information&lt;/a&gt; on this topic.  At least I never actually tried to install ArcSDE with the -o option as the first error message instructed me to do.&lt;/p&gt;
&lt;div id=&#34;geo-post-284&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.979965&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.263836&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Displaying Node Dangles in Arcedit</title>
      <link>https://maprantala.com/2011/01/06/displaying-node-dangles-in-arcedit/</link>
      <pubDate>Thu, 06 Jan 2011 16:50:42 -0600</pubDate>
      <guid>https://maprantala.com/2011/01/06/displaying-node-dangles-in-arcedit/</guid>
      <description>&lt;p&gt;Since the name of the blog is Node Dangles, I get several hits daily from searches on &amp;lsquo;Node Dangles&amp;rsquo; and I have no  information on node dangles.  This post is the first in a series to change that.&lt;/p&gt;
&lt;p&gt;First let us, by us, I mean &lt;a href=&#34;http://www.esri.com/&#34; target=&#34;_blank&#34;&gt;ESRI&lt;/a&gt;, define what a node dangle is.  Their online glossary actually defines a &lt;a href=&#34;https://resources.arcgis.com/glossary/term/215&#34; target=&#34;_blank&#34;&gt;dangling arc&lt;/a&gt;, a dangling node is a &lt;a href=&#34;https://resources.arcgis.com/glossary/term/71&#34; target=&#34;_blank&#34;&gt;node&lt;/a&gt; (endpoint of an arc) that does the non-connecting mentioned below:&lt;/p&gt;
&lt;p style=&#34;padding-left:30px;&#34;&gt;
  &#39;An arc having the same polygon on both its left and right sides and having at least one node that does not connect to any other arc. It often occurs where a polygon does not close properly, where arcs do not connect properly (an undershoot), or where an arc was digitized past its intersection with another arc (an overshoot). A dangling arc is not always an error; for example, it can represent a cul-de-sac in a street network.&#39;
&lt;/p&gt;
&lt;p&gt;Matt&amp;rsquo;s definition is &amp;lsquo;a node that isn&amp;rsquo;t connected to any other node&amp;rsquo;.  The Arcedit screen shot below shows a coverage of roads and its arcs (white lines), nodes (white squares) at the ends of the arcs, and node dangles (red squares) indicating what nodes are dangling.  Too bad clearly flagging &lt;a href=&#34;(http://en.wikipedia.org/wiki/United_States_presidential_election,_2000&#34; target=&#34;_blank&#34;&gt;dangling chads&lt;/a&gt; isn&amp;rsquo;t so easy.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2011/01/dangles.jpg?resize=629%2C598&#34; alt=&#34;Node Dangles in ArcEdit&#34;&gt;&lt;/p&gt;
&lt;p&gt;Displaying (and illustrating) how to display dangling nodes in Arcedit is simple, the command is&lt;/p&gt;
&lt;p&gt; &#39;drawenvironment node dangle&#39;&lt;/p&gt; 
or, as I&#39;ve done above, 
&lt;p&gt;&#39;drawe node dangle&#39;.&lt;/p&gt; 
To display the dangles in a different color than the default white, follow-up with the command &#39;nodecolor dangle 2&#39;.  The 2 is ESRI&#39;s value for red.</description>
    </item>
    
    <item>
      <title>Multiple outputs for Python scripts</title>
      <link>https://maprantala.com/2010/12/17/multiple-outputs-for-python-scripts/</link>
      <pubDate>Fri, 17 Dec 2010 15:19:38 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/17/multiple-outputs-for-python-scripts/</guid>
      <description>&lt;p&gt;Related to my &lt;a href=&#34;https://maprantala.com/2010/12/13/launching-a-python-script-with-parameters-3-methods/&#34;&gt;post&lt;/a&gt; on how I enable a script to accept parameters from different sources, I also often set up pythons scripts to output information a variety of ways.  This is largely due to the fact that some are called by ArcToolbox scripts.  Running in ESRI&amp;rsquo;s domain, these scripts need to send the output through the arcgisscripting object but if you are running the python outside the ArcGIS framework, you can just print.&lt;/p&gt;
&lt;p&gt;If you assume one output method but then run your code in the opposite framework, you don&amp;rsquo;t get to see all the pretty little messages.  What I do is create a simple little routine that broadcasts the message both ways.  This is probably an obvious solution but took a few cases before I went ahead and started implementing it.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;gp &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcgisscripting&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;create()

&lt;span style=&#34;color:#75715e&#34;&gt;#This will print both to the geoprocessing window or Python output window&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;gpprint&lt;/span&gt;(inmessage):
 gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;addmessage(inmessage)
 &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inmessage

&lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt;Code to do stuff&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt;

&lt;span style=&#34;color:#75715e&#34;&gt;#Ok, I want to send a message:&lt;/span&gt;
gpprint(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Hello, sailor!&amp;#39;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Zipping a shapefile via ArcToolbox</title>
      <link>https://maprantala.com/2010/12/15/zipping-a-shapefile-via-arctoolbox/</link>
      <pubDate>Wed, 15 Dec 2010 14:36:04 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/15/zipping-a-shapefile-via-arctoolbox/</guid>
      <description>&lt;h2 id=&#34;update&#34;&gt;&lt;strong&gt;UPDATE:&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;https://maprantala.com/2014/05/06/zipping-a-shapefile-from-arccatalog/&#34;&gt;After receiving a request to modify the code to ignore .lock files, I have an updated to this post.&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve received a request on how to use the &lt;a href=&#34;https://maprantala.com/2010/12/10/zipping-a-shapefile-using-python/&#34;&gt;Zip Shapefile&lt;/a&gt; code I posted last week from ArcGIS. Sorry, I did not set the code up to call directly from ArcGIS but only as an illustration of how it can be done.&lt;/p&gt;
&lt;p&gt;I have, however, with some minor tweaking, made a version that can added to ArcToolbox. The steps to install are below, please note that at one point I had you download a *.zip file that had been renamed to *.jpg–this should now be corrected and the link should lead you directly to zipshapefile.zip.  Because of this steps two and three are obsolete.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Download the code from here.&lt;/li&gt;
&lt;li&gt;&lt;del&gt;Rename the file from zipshapefile-zip.jpg back to zipshapefile.zip.&lt;/del&gt;&lt;/li&gt;
&lt;li&gt;Unzip the file.&lt;/li&gt;
&lt;li&gt;Move ZipShapefile.py to C:Program FilesArcGISArcToolBoxScriptsZipShapefile.py.&lt;/li&gt;
&lt;li&gt;Optionally, move Zip Shapefile.tbx, perhaps C:Program FilesArcGISArcToolBoxToolboxes.&lt;/li&gt;
&lt;li&gt;Add the toolbox to ArcToolbox. ESRI has instructions &lt;a href=&#34;http://webhelp.esri.com/arcgisdesktop/9.3/tutorials/spatial/Spatial_14.htm&#34; target=&#34;_blank&#34;&gt;here&lt;/a&gt; on how to do this.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;You should now have a new toolbox named &amp;lsquo;Zip Shapefile&amp;rsquo; with a script named &amp;lsquo;Zip a Shapefile&amp;rsquo; in it. Clicking on on the tool will bring up this dialog.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/12/capture.jpg?resize=271%2C71&#34; alt=&#34;Zip a Shapefile Dialog&#34;&gt;&lt;/p&gt;
&lt;p&gt;*&lt;strong&gt;*&lt;/strong&gt;*&lt;strong&gt;*&lt;/strong&gt;*&lt;strong&gt;*&lt;/strong&gt;*&lt;strong&gt;*&lt;/strong&gt;*&lt;strong&gt;*&lt;/strong&gt;****&lt;br&gt;
In response to Chris:&lt;/p&gt;
&lt;p&gt;I believe you need to copy the ZipShapefile.py file from the .zip that you downloaded to C:Program FilesArcGISArcToolBoxScripts, the error message is consistent with the tool not being about to find the python script there.&lt;/p&gt;
&lt;p&gt;If you prefer to place the ZipShapefile.py in a different location, you will need to change the source on the tool. To do this, right click on the tool in ArcCatalog and change the path of the Script File as set in the Source tab (see below):
&lt;img src=&#34;https://maprantala.com/images/2012/03/setpath.png?resize=494%2C265&#34; alt=&#34;set Path&#34;&gt;&lt;/p&gt;
&lt;div id=&#34;geo-post-246&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Launching a Python script with parameters–3 methods.</title>
      <link>https://maprantala.com/2010/12/13/launching-a-python-script-with-parameters3-methods./</link>
      <pubDate>Mon, 13 Dec 2010 14:56:43 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/13/launching-a-python-script-with-parameters3-methods./</guid>
      <description>&lt;p&gt;Since I use python for different tasks, I launch python scripts a variety of ways. Depending on what I am doing, a single script may need to accept parameters from either:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Passed in from an ArcGIS Toolbox Tool.&lt;/li&gt;
&lt;li&gt;Re-occurring default value.  Often used in scheduled processes, a nightly backup, for example.&lt;/li&gt;
&lt;li&gt;A temporary set of values used in an interactive, debugging session.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;What I often do is make the parameter interpretation flexible to meet my needs.  The sample below shows how I do this.  The logic first checks to see if the correct number of parameters were used to launch the script (i.e. if it is called by an Arc Toolbox tool), where the files for the default files exist or if the debug values are valid, including checking the current date against a hard-coded date variable.  Juggling the conditional structure would allow you to prioritize the options differently.&lt;/p&gt;
&lt;p&gt;I am also using Tkinter to display an interactive dialog if none of the three conditions are successfully met.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import os.path
import datetime
import shutil
import sys

theEmailText = &amp;quot;nStart: &amp;quot; + str(datetime.datetime.now())

#This example shows three different ways for a script to receive input paramters.
#
# First, if it was run with the necessary number of parameters, as if launched by
# an ArcToolbox tool, it uses those parameters.

if len(sys.argv) == 2:
    wellsShapeFile = sys.argv[0]
    unwellsShapeFile = sys.argv[1]
    theEmailText = theEmailText + &amp;quot;nUsing Parameters Passed In:nn Located Wells File: &amp;quot;+wellsShapeFile+&amp;quot;n Unlocated Wells File: &amp;quot;+unwellsShapeFile
else:
    dateString = datetime.date.today().strftime(&amp;quot;%Y%m%d&amp;quot;)
    wellsShapeFile = &amp;quot;C:/cwi5_bk/wells/temp/wells_.shp&amp;quot;
    unwellsShapeFile = &amp;quot;C:/cwi5_bk/wells/temp/unloc_wells.shp&amp;quot;

    #Second attempt is if there are default values that should be used.
    #I use this for a process that is run via scheduled Windows Task
    if (os.path.exists(wellsShapeFile)) and (os.path.exists(unwellsShapeFile)):
        theEmailText = theEmailText + &amp;quot;nUsing Automated Date-Based file names:nn Located Wells File: &amp;quot;+wellsShapeFile+&amp;quot;n Unlocated Wells File: &amp;quot;+unwellsShapeFile
    else:
        #The third method is used for debugging/running in the IDE.
        #I put a check condition so this is valid for one day only
        #And then hard-code the temporary paths.
        #
        #Note that you may want to modify the structure of the IF statement
        #used for methods 2 &amp;amp; 3 so that it checks for the manual-override (3rd)
        #method first
        if dateString == &#39;20101213&#39;:
            wellsShapeFile = &amp;quot;C:/cwi5_bk/wells/temp/wells.shp&amp;quot;
            unwellsShapeFile = &amp;quot;C:/cwi5_bk/wells/temp/unloc.shp&amp;quot;
            theEmailText = theEmailText + &amp;quot;nUsing Manual Override file names:nn Located Wells File: &amp;quot;+wellsShapeFile+&amp;quot;n Unlocated Wells File: &amp;quot;+unwellsShapeFile
        else:
            theEmailText = theEmailText + &amp;quot;n Manual Override for file names does not meet data filter&amp;quot;

    if (not os.path.exists(wellsShapeFile)) or (not os.path.exists(unwellsShapeFile)):
        from Tkinter import *
        msgbox = Tk()
        msgbox.title(&#39;Error&#39;)
        Message(msgbox,text=&amp;quot;Must either use ArcTool to launch or edit file parameters&amp;quot;, bg=&#39;royalblue&#39;,fg=&#39;ivory&#39;, relief=GROOVE).pack(padx=10, pady=10)
        msgbox.mainloop()
        print theEmailText
        quit()

print theEmailText
&lt;/code&gt;&lt;/pre&gt;&lt;div id=&#34;geo-post-252&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Zipping a shapefile using python</title>
      <link>https://maprantala.com/2010/12/10/zipping-a-shapefile-using-python/</link>
      <pubDate>Fri, 10 Dec 2010 18:20:13 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/10/zipping-a-shapefile-using-python/</guid>
      <description>&lt;h2 id=&#34;update&#34;&gt;&lt;strong&gt;UPDATE:&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;https://maprantala.com/2014/05/06/zipping-a-shapefile-from-arccatalog/&#34;&gt;After receiving a request to modify the code to ignore .lock files, I have an updated to this post.&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;One of the tasks I&amp;rsquo;ve been automating is publishing a weekly data update to a website. The update consists of shapefile. The trouble with shapefiles is they consist of 3 or more files with the same basename but different extensions in the same directory.&lt;/p&gt;
&lt;p&gt;Not an overly complicated situation but a common one that ArcGIS does not have a solution out-of-the-box. Below is a bare-bones code snippet to do it. It has both the input shapefile and output zip file hard-coded. The call to the subroutine that does the work is: zipShapefile(wellsShapeFile,wellsZipFile)&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; zipfile
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sys
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; os
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; glob
wellsShapeFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/cwi5_bk/WELLS/wells.SHP&amp;#34;&lt;/span&gt;
wellsZipFile &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/cwi5_bk/WELLS/test5.zip&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;zipShapefile&lt;/span&gt;(inShapefile, newZipFN):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Starting to Zip &amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;inShapefile&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39; to &amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;newZipFN

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;not&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exists(inShapefile)):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inShapefile &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39; Does Not Exist&amp;#39;&lt;/span&gt;
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exists(newZipFN)):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Deleting &amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;newZipFN
   os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;remove(newZipFN)

&lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;exists(newZipFN)):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Unable to Delete&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;newZipFN
   &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; False

zipobj &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; zipfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ZipFile(newZipFN,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;w&amp;#39;&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; infile &lt;span style=&#34;color:#f92672&#34;&gt;in&lt;/span&gt; glob&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;glob( inShapefile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;lower()&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;replace(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;.shp&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;.*&amp;#34;&lt;/span&gt;)):
   &lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; infile
   zipobj&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;write(infile,os&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;path&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;basename(infile),zipfile&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ZIP_DEFLATED)

zipobj&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;close()
&lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; True

zipShapefile(wellsShapeFile,wellsZipFile)
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;done!&amp;#34;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div id=&#34;geo-post-236&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.979965&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.263836&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>X-section Xacto Updated</title>
      <link>https://maprantala.com/2010/12/10/x-section-xacto-updated/</link>
      <pubDate>Fri, 10 Dec 2010 18:15:51 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/10/x-section-xacto-updated/</guid>
      <description>&lt;p&gt;I just happened to stumble upon an update of a tool to Create Geologic Cross Sections, eXacto Section v. 2.0, that I &lt;a href=&#34;https://maprantala.com/2010/07/23/create-geologic-cross-sections-exacto-section-v-2-0-arcmap-9-3/&#34;&gt;mentioned&lt;/a&gt; in July. Jennifer Carrell at the Illinois Geological Survey wrote this tool. The latest update is from December 8, 2010 and can be &lt;a href=&#34;http://resources.arcgis.com/gallery/file/geoprocessing/details?entryID=C83CC388-1422-2418-7F10-B4D3DF5F1EE6&#34; target=&#34;_blank&#34;&gt;downloaded at ESRI&amp;rsquo;s ArcGIS Resource Center&lt;/a&gt;. Our office has used previous versions and finds in very useful in creating cross-sections. I have not tried this latest update.&lt;/p&gt;
&lt;div id=&#34;geo-post-240&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Example of how to add controls in data grid VB.NET</title>
      <link>https://maprantala.com/2010/12/09/example-of-how-to-add-controls-in-data-grid-vb.net/</link>
      <pubDate>Thu, 09 Dec 2010 17:15:35 -0600</pubDate>
      <guid>https://maprantala.com/2010/12/09/example-of-how-to-add-controls-in-data-grid-vb.net/</guid>
      <description>&lt;p&gt;I have been working on some data entry forms that utilize a DataGrid.  Using a PostGres Geodatabase that had domains set on several fields, I could not directly bind to the controls on my dialog.  So I am going the round-about way of populating my own comboboxes with valid names and displaying within the DataGrid.&lt;/p&gt;
&lt;p&gt;Having not done this previously, I found this example: &lt;a href=&#34;http://www.eggheadcafe.com/community/aspnet/14/22477/example-of-how-to-add-controls-in-data-grid.aspx&#34; target=&#34;_blank&#34;&gt;Example of how to add controls in data grid VB.NET&lt;/a&gt; very useful and just wanted to point it out to anyone. &lt;a href=&#34;http://www.syncfusion.com/FAQ/windowsforms/faq_c44c.aspx#q1015q&#34; target=&#34;_blank&#34;&gt;George Shephard&amp;rsquo;s Windows Forms FAQ&lt;/a&gt;  also had several useful tips.&lt;/p&gt;
&lt;p&gt;Finally, I has a problem with the masked textboxs I added to the Datagrid, they required users to click once to get focus and a second to start editing.  After much googling, I found used some information from &lt;a href=&#34;http://social.msdn.microsoft.com/Forums/en-US/vbgeneral/thread/8d3c1f98-9501-4902-b81b-82f6bbd4f3e5/&#34; target=&#34;_blank&#34;&gt;MSDN&lt;/a&gt; that allowed me to find a work-around.  In my Mousedown event, I included this snippet (QdiControl is the control for the specific cell that the HitTestInfo says the mousedown hit):&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Dim WindowsControl As System.Windows.Forms.Control = CType(QdiControl, System.Windows.Forms.Control)
If (TypeOf WindowsControl Is MaskedTextBox) Then
 Dim pTextBox As MaskedTextBox = CType(WindowsControl, MaskedTextBox)
 Dim dgdtblStyle As DataGridColumnStyle = RelatedForm.DataGrid.TableStyles(0).GridColumnStyles(CurrentColumn)

 RelatedForm.DataGrid.BeginEdit(dgdtblStyle, CurrentRow)
 pTextBox.Select(pTextBox.Text.Length, 0)
 WindowsControl.Focus()

 End If
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Peace.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap Copy and Paste Features</title>
      <link>https://maprantala.com/2010/10/13/arcmap-copy-and-paste-features/</link>
      <pubDate>Wed, 13 Oct 2010 16:28:39 -0500</pubDate>
      <guid>https://maprantala.com/2010/10/13/arcmap-copy-and-paste-features/</guid>
      <description>&lt;p&gt;Sometimes it seems like I could write the data down by long hand faster than ArcMap can copy &amp;amp; paste features from one feature class to another. geeeeezzz.&lt;/p&gt;
&lt;div id=&#34;geo-post-226&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;44.852994&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;-93.55073&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Another TopoToRaster Error</title>
      <link>https://maprantala.com/2010/09/15/another-topotoraster-error/</link>
      <pubDate>Wed, 15 Sep 2010 13:36:34 -0500</pubDate>
      <guid>https://maprantala.com/2010/09/15/another-topotoraster-error/</guid>
      <description>&lt;h3 id=&#34;subtitled-why-error-messages-are-good&#34;&gt;Subtitled:  Why error messages are good.&lt;/h3&gt;
&lt;p&gt;Came up with another error while running TopoToRaster but this time ArcGIS gave an error message that led to a solution.  Turned out all my contour lines had an elevation of 16 which TopoToRaster did not like.  I had intended to increase the elevation and inadvertently set them all to sixteen.  I had saved the previous values before editing so it turned out to be a simple fix and I didn&amp;rsquo;t have to spend a day trying figure out what was wrong.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/09/sixteen.jpg?resize=630%2C225&#34; alt=&#34;Sixteen&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>TopoToRaster Error</title>
      <link>https://maprantala.com/2010/09/13/topotoraster-error/</link>
      <pubDate>Mon, 13 Sep 2010 20:25:01 -0500</pubDate>
      <guid>https://maprantala.com/2010/09/13/topotoraster-error/</guid>
      <description>&lt;p&gt;In running an automated process, I had a TopoToRaster repeatedly fail on me. The only input theme was a contour theme. The process ran fine when I used the envelope of the contour theme as the output extent but when I changed it to the envelope of a polygon theme, it would bomb. The polygon&amp;rsquo;s envelope was smaller than the contour theme.&lt;/p&gt;
&lt;p&gt;ArcCatalog would bomb out without presenting any sort of useful message.&lt;/p&gt;
&lt;p&gt;I determined eventually that If I set the left extent as 435210, the process would work if set the right extent to 446655 or greater but would bomb if I used 446654 or less. If the the left extent was 435209, the right extent had to be 446654 or greater.&lt;/p&gt;
&lt;p&gt;The image below shows the contours (with vertexes) and the polygon theme I was using. The two circle graphics show the approximate extent I was clipping to.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images//2010/09/topotoraster.jpg?resize=453%2C381&#34; alt=&#34;topotoRaster&#34;&gt;&lt;/p&gt;
&lt;p&gt;I eventually wrote python script to do a series of tests with the intent of determining the pattern of what does and does not work. The unexpected benefit was I actually got some sort of error message back. Turns out it had to do with my lack of vertices–I densified my polylines and it ran fine. Something I should have thought of earlier but it was difficult lacking any feedback.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/09/untitled.jpg?resize=535%2C271&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcBruTile</title>
      <link>https://maprantala.com/2010/09/09/arcbrutile/</link>
      <pubDate>Thu, 09 Sep 2010 14:38:46 -0500</pubDate>
      <guid>https://maprantala.com/2010/09/09/arcbrutile/</guid>
      <description>&lt;p&gt;Stumbled across &lt;a href=&#34;https://bertt.itch.io/arcbrutile&#34; target=&#34;_blank&#34;&gt;ArcBruTile&lt;/a&gt;, an ArcMap application that allows you to display map tile services–such as &lt;a href=&#34;http://www.openstreetmap.org/&#34; target=&#34;_blank&#34;&gt;OpenStreetMap&lt;/a&gt;, &lt;a href=&#34;http://maps.google.com/&#34; target=&#34;_blank&#34;&gt;Google Maps&lt;/a&gt;, &lt;a href=&#34;http://www.bing.com/maps/&#34; target=&#34;_blank&#34;&gt;Bing&lt;/a&gt;, &lt;a href=&#34;http://www.spatialcloud.com/&#34; target=&#34;_blank&#34;&gt;Spatial Cloud&lt;/a&gt;, and &lt;a href=&#34;http://wiki.osgeo.org/wiki/Tile_Map_Service_Specification&#34; target=&#34;_blank&#34;&gt;Tile Map Service&lt;/a&gt; (TMS)–in your ArcMap documents.   It works pretty well from my preliminary testing of it.   I have found that at times that the graphical tiles are distorted but I am guessing it is because they are optimized for display in a specific projection, at specific scales and, in ArcMap, you can use any projection/scale combination you want.&lt;/p&gt;
&lt;p&gt;This is a free, open-source project that is still in Beta but definitely an application I plan to keep an eye on.  As with any open-source project, the cool thing is the code is available for you to look at, learn from, and hopefully contribute to.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Icon Transparency</title>
      <link>https://maprantala.com/2010/09/08/icon-transparency/</link>
      <pubDate>Wed, 08 Sep 2010 15:47:36 -0500</pubDate>
      <guid>https://maprantala.com/2010/09/08/icon-transparency/</guid>
      <description>&lt;p&gt;Maybe I am just dense, but skimming &lt;a href=&#34;https://c.na1.visual.force.com/apex/ideaView?id=0873000000088YVAAY&#34; target=&#34;_blank&#34;&gt;ArcIdeas&lt;/a&gt;, I found out that the transparency for an icon is determined by the upper-left pixel.  Don&amp;rsquo;t know if this is an ESRI convention or not but thought I would pass it one.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Workstation ArcInfo Interchange Import Error</title>
      <link>https://maprantala.com/2010/09/07/workstation-arcinfo-interchange-import-error/</link>
      <pubDate>Tue, 07 Sep 2010 19:08:39 -0500</pubDate>
      <guid>https://maprantala.com/2010/09/07/workstation-arcinfo-interchange-import-error/</guid>
      <description>&lt;p&gt;I have been working on updating some data that was published using Arc/Info Workstation Export (.e00) files, converting them to shapefiles, or in the case of annotation, to a geodatabase feature class.&lt;/p&gt;
&lt;p&gt;While converting some INFO tables, I have received this error:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/09/importerror1.jpg?resize=630%2C255&#34; alt=&#34;ImportError&#34;&gt;&lt;/p&gt;
&lt;p&gt;It turns out that Workstation can create export files that contain values that did not fit within their field–I&amp;rsquo;m guessing that somehow you are actually able to enter invalid values into those fields but I did not confirm that.&lt;/p&gt;
&lt;p&gt;The error, &amp;lsquo;Unable to encode the 38th item in the 65th record…&amp;rsquo; was only partially helpful.  The error was in the 65th record but I was not able figure out which field contained the error.  The nature assumption that it was the 38th column was incorrect, at least if you are counting from left to right.  Whatever logic that is used, is consistent, at least within a specific table, because I had numerous records with problems and when the error messages indicated it was the same item, it did turn out to be the same field.&lt;/p&gt;
&lt;p&gt;What I ended up having to do was open the export file in my favorite text editor, locating the info for problematic record and go through the columns one-by-one, comparing the value in the text file with that in the table.  In this case, 14.1 was suppose to be the value in the WP_TIO2 field.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/09/testfile.jpg?resize=630%2C352&#34; alt=&#34;TestFile&#34;&gt;&lt;/p&gt;
&lt;p&gt;One thing I noticed, and this is consistent with behavior I have observed in ArcObjects in other cases, is that the record with the invalid value in a field ends up with the same value in that field as the previous record.  So in this case, the bad record has a value of 1.12 in the WP_TIO2 field because that is what previous record has.   That leads me to believe that ArcObjects is re-using a variable as it does the import, just updating each value, field-by-field.
&lt;img src=&#34;https://maprantala.com/images/2010/09/badvalue.jpg?resize=630%2C100%22&#34; alt=&#34;BadValue&#34;&gt;&lt;/p&gt;
&lt;p&gt;Just to make sure that I had diagnosed the problem right, I attempted to change the value to 14.1 in an ArcMap edit session and got this message:&lt;br&gt;
&lt;img src=&#34;https://maprantala.com/images/2010/09/editerror1.jpg?resize=630%2C196&#34; alt=&#34;EditError&#34;&gt;&lt;/p&gt;
&lt;p&gt;A look at the field properties confirmed that the field would not accept 14.1 as a value. The precision (3) means the field can hold 3 digits with 2 (the Scale) of them being right of the decimal point–leaving only one digit available to the left of the decimal point.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/09/filedproperties.jpg?resize=437%2C419&#34; alt=&#34;FiledProperties&#34;&gt;&lt;/p&gt;
&lt;p&gt;Once I identified the problem, I used two methods to correct it. The majority of my cases were actually cases where a psuedo-null value was being used to indicate that a field was really Null. In some cases, either -999.9 or 100 were being used. In these cases, I just substituted a different psuedo-null value (-99.9) that conformed to the field limitations. The data I was working with was not tightly controlled in the past and there were other existing records that used these value for the same fields, so I was able to do this without much concern.&lt;/p&gt;
&lt;p&gt;Some values, however, were not nulls and I felt needed to be retained. These, I had to add a new field that could contain the values, copy the values over and then edit the ones that had caused problems during the import. Once complete, I exported the data to a new table with the new table structure I created.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Trying to perform &#39;relate&#39; in Model Builder</title>
      <link>https://maprantala.com/2010/08/11/trying-to-perform-relate-in-model-builder/</link>
      <pubDate>Wed, 11 Aug 2010 17:31:21 -0500</pubDate>
      <guid>https://maprantala.com/2010/08/11/trying-to-perform-relate-in-model-builder/</guid>
      <description>&lt;p&gt;I was using Model Builder (ugh!) to select records in one table (CWI.C5ST) that relate to a subset of records ([BHGEOPHYS] = &amp;lsquo;Y&amp;rsquo;) in another table (CWI.C5IX).  There is not an existing tool for doing this in ArcGIS.  I did find a &lt;a href=&#34;http://forums.esri.com/Thread.asp?c=93&amp;f=1728&amp;t=257179&amp;g=1&#34; target=&#34;_blank&#34;&gt;post&lt;/a&gt; by Layne Seely in &lt;a href=&#34;http://forums.esri.com/&#34; target=&#34;_blank&#34;&gt;ArcForums&lt;/a&gt; titled &amp;lsquo;trying to perform &amp;lsquo;relate&amp;rsquo; in Model Builder.&amp;rsquo; that led me to the Make Table View under Data Management Tools-Make Table View and even had  the basic syntax I was looking for (if it hadn&amp;rsquo;t I probably would have guessed that it would not allow subqueries).&lt;/p&gt;
&lt;p&gt;Since I always like to see exactly the syntax someone uses, I decided to show the syntax I used in case that helps anyone else.&lt;figure id=&#34;attachment_171&#34; aria-describedby=&#34;caption-attachment-171&#34; style=&#34;width: 615px&#34; class=&#34;wp-caption alignnone&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/08/tableview.jpg?resize=615%2C392&#34; alt=&#34;tableView&#34;&gt;&lt;/p&gt;
&lt;p&gt;It does require that the tables reside in the same workspace, which is a reasonable limitation that I can live with.  Another drawback is that if you export the model to a python script, the command can get pretty long, especially if you have many fields.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Utah Geological Survey</title>
      <link>https://maprantala.com/2010/08/04/utah-geological-survey/</link>
      <pubDate>Wed, 04 Aug 2010 16:50:04 -0500</pubDate>
      <guid>https://maprantala.com/2010/08/04/utah-geological-survey/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://geology.utah.gov/&#34; target=&#34;_blank&#34;&gt;Utah Geological Survey&lt;/a&gt; has a good supply of &lt;a href=&#34;http://geology.utah.gov/maps/geomap/index.htm&#34; target=&#34;_blank&#34;&gt;Maps&lt;/a&gt; and &lt;a href=&#34;http://geology.utah.gov/maps/gis/index.htm&#34; target=&#34;_blank&#34;&gt;data&lt;/a&gt; available online and some &lt;a href=&#34;http://geology.utah.gov/maps/index.htm&#34; target=&#34;_blank&#34;&gt;online maps&lt;/a&gt;. They also have an online &lt;a href=&#34;http://geology.utah.gov/blog/&#34; target=&#34;_blank&#34;&gt;Blog&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The GIS data is a fairly complete package–the sample I downloaded included .pdfs, shapefiles, layer files, images and ArcMap project (.MXD) files used to generate the .pdfs.  File sizes are larger because of the completeness.  Feature classes have a moderate level of attribution.&lt;/p&gt;
&lt;p&gt;The highlight, however, are the sample &lt;a href=&#34;http://geology.utah.gov/geo_guides/st_george/index.htm&#34; target=&#34;_blank&#34;&gt;Keyhole Markup (KMZ) files&lt;/a&gt; of the of the St. George 30′ x 60′ quadrangle that can be viewed in Google Earth.  Too cool.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Accessing Network Drives via Scheduled Python Task</title>
      <link>https://maprantala.com/2010/07/26/accessing-network-drives-via-scheduled-python-task/</link>
      <pubDate>Mon, 26 Jul 2010 12:43:02 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/26/accessing-network-drives-via-scheduled-python-task/</guid>
      <description>&lt;p&gt;As previously mentioned, I have a scheduled nightly backup that is written in Python.  Most of it has been working fine but I had not gotten it to copy files to network drives.  I finally got around to correcting that part.  My first attempt was just to map the network drives for the user account that is used to run the task.  No good.&lt;/p&gt;
&lt;p&gt;My second attempt was to call a .bat file from python before accessing the network drives and that worked.&lt;/p&gt;
&lt;p&gt;The batch file has two lines (one for each network drive):&lt;/p&gt;
&lt;p&gt;net use n: \domain1sharename mypassword /USER:domainusername&lt;br&gt;
net use t: \domain2sharename mypassword /USER:domainusername&lt;/p&gt;
&lt;p&gt;And my python script includes two lines to call it before I access the network locations:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;import os
os.system(&#39;C:/cwi5_bk/mapDrive.bat&#39;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Arizona Geological Survey</title>
      <link>https://maprantala.com/2010/07/23/arizona-geological-survey/</link>
      <pubDate>Fri, 23 Jul 2010 19:07:52 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/23/arizona-geological-survey/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.azgs.az.gov/&#34; target=&#34;_blank&#34;&gt;The Arizona Geological Survey&lt;/a&gt; has a great looking site with some good information.  They have a &lt;a href=&#34;http://www.azgs.az.gov/publications_online/pubslist_2008.pdf&#34; target=&#34;_blank&#34;&gt;publication list&lt;/a&gt; that can either be downloaded or ordered and are making pdf versions of their recent publications available &lt;a href=&#34;http://www.azgs.az.gov/publications_online.shtml&#34; target=&#34;_blank&#34;&gt;online&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I was going to note that there was no download-able data available until Google told me that they in fact had a &lt;a href=&#34;http://www.azgs.az.gov/services_azgeomap.shtml&#34; target=&#34;_blank&#34;&gt;WMS/WFS available online&lt;/a&gt;.  The WMS is a great looking map, I have not gotten the WFS to work, however–probably more due to my abilities than the service.&lt;/p&gt;
&lt;p&gt;They are also temporarily hosting a &lt;a href=&#34;http://services.azgs.az.gov/OnlineMaps/demos/nvClarkCounty.html&#34; target=&#34;_blank&#34;&gt;surficial geology map&lt;/a&gt; of Clark County, Nevada.&lt;/p&gt;
&lt;p&gt;Lee Allison, the State Geologist, also has a &lt;a href=&#34;http://arizonageology.blogspot.com/&#34; target=&#34;_blank&#34;&gt;blog&lt;/a&gt; with frequent postings.  One of which led me to the Nation Park Service&amp;rsquo;s &lt;a href=&#34;http://science.nature.nps.gov/nrdata/&#34; target=&#34;_blank&#34;&gt;Data Store&lt;/a&gt; which is worth a look.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Create Geologic Cross Sections–eXacto Section v. 2.0, ArcMap 9.3</title>
      <link>https://maprantala.com/2010/07/23/create-geologic-cross-sectionsexacto-section-v.-2.0-arcmap-9.3/</link>
      <pubDate>Fri, 23 Jul 2010 13:59:44 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/23/create-geologic-cross-sectionsexacto-section-v.-2.0-arcmap-9.3/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://arcscripts.esri.com/details.asp?dbid=16734&#34; target=&#34;_blank&#34;&gt;Create Geologic Cross Sections–eXacto Section v. 2.0, ArcMap 9.3&lt;/a&gt; written by Jennifer Carrell of the &lt;a href=&#34;http://www.isgs.illinois.edu/&#34; target=&#34;_blank&#34;&gt;Illinois State Geological Survey&lt;/a&gt; is a handy tool for creating cross sections.&lt;/p&gt;
&lt;p&gt;It requires ArcGIS and a 3D Analyst Extension license.&lt;/p&gt;
&lt;p&gt;You can create profiles against multiple DEMs at once, define the vertical exaggeration, and have it include contact points.  It is well documented and comes with sample data to use with the tutorial.&lt;/p&gt;
&lt;p&gt;I did not see it mentioned but it also include a personal geodatabase that include a grid that can be used along with the profiles you create.&lt;/p&gt;
&lt;p&gt;If  you make profiles, think this is definitely an option you should look at.  The fact that it is a VBA application is a bit worrisome in that its lifespan is limited.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Michigan Office of Geological Survey</title>
      <link>https://maprantala.com/2010/07/22/michigan-office-of-geological-survey/</link>
      <pubDate>Thu, 22 Jul 2010 15:31:20 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/22/michigan-office-of-geological-survey/</guid>
      <description>&lt;p&gt;The Michigan &lt;a href=&#34;http://www.michigan.gov/deq/0,1607,7-135-3306_57064-87386--,00.html&#34; target=&#34;_blank&#34;&gt;Office of Geological Survey&lt;/a&gt; appears to have pdf versions of all the documents in their &lt;a href=&#34;http://www.michigan.gov/documents/deq/GIMDL-Catalog-2010-01-20_307979_7.pdf&#34; target=&#34;_blank&#34;&gt;Digital Geological Library&lt;/a&gt; available for download.  The transcripts of some early (beginning in 1871) &lt;a href=&#34;http://www.michigan.gov/documents/deq/OFR_19_Rominger_1871-1874_Aopt_306084_7.pdf&#34; target=&#34;_blank&#34;&gt;field notes&lt;/a&gt; are a fun inclusion in the available archives.&lt;/p&gt;
&lt;p&gt;Actual GIS data was a bit hard to find although I found both bedrock geology and quarternary geology available from the state &lt;a href=&#34;http://www.mcgi.state.mi.us/mgdl/?action=thm&#34; target=&#34;_blank&#34;&gt;Geographic Data Library&lt;/a&gt; in shapefile format.  I also found oil and gas well data but did not download it.&lt;/p&gt;
&lt;p&gt;The data carried minimal attribution, one interesting thing I found in the bedrock data was the red, green, blue values apparently used for each polygon.&lt;/p&gt;
&lt;p&gt;One thing to be aware of is that the shapefiles do not come with a prj file which could be a problem.  Michigan has their own defined coordinate system called &lt;a href=&#34;http://www.michigan.gov/documents/DNR_Map_Proj_and_MI_Georef_Info_20889_7.pdf&#34; target=&#34;_blank&#34;&gt;Michigan GeoRef&lt;/a&gt;.  This coordinate system defines the entire state into a single zone instead of multiple zones like the USGS&#39; stateplane system does.  This is nice to work with UNLESS it comes undocumented as I found out while doing some consulting work in Au Train, Michigan a decade ago–I was able to finally find something online about it around 2 am one morning but I think I still have scars from the head-pounding that occurred that night.&lt;/p&gt;
&lt;p&gt;ESRI, however, makes it easy to deal with this data–they include the specifications for Michigan GeoRef in inventory of predefined coordinate systems that ships with ArcGIS.  If you define the projection on each shapefile, it will then load automatically in real-world coordinates.  To define the projection on a shapefile, right-click on it in ArcCatalog and select &amp;lsquo;Properties…&#39;.  Select &amp;lsquo;XY Coordinate System&amp;rsquo; on the Shapefile Properties dialog.  Hit the &amp;lsquo;Select&amp;rsquo; button and navigate to Projected Coordinate Systems-State Sytems-NAD 1983 Michigan GeoRef (Meters).prj.  Hit the &amp;lsquo;Add&amp;rsquo; button and then the &amp;lsquo;Apply&amp;rsquo; button.  Repeat for any other shapefiles you download.&lt;/p&gt;
&lt;p&gt;One item I found out about ArcGIS while doing this is that if you change the projection on a shapefile, it will recognize that change the next time you use that data.  I originally set the units to be feet on the data so it did not load in the proper real-world location.  I saved my ArcMap document, quit out, and corrected the problem.  When I re-opened the document, Michigan had migrated back to where we are used to seeing it.  This contrasts with how ArcView 3.x use to handle raster data, you had to actually remove the layer from your view and re-load it to recognize the change in spatial references.&lt;/p&gt;
&lt;div id=&#34;geo-post-125&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Wisconsin Geological and Natural History Survey</title>
      <link>https://maprantala.com/2010/07/15/wisconsin-geological-and-natural-history-survey/</link>
      <pubDate>Thu, 15 Jul 2010 13:18:28 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/15/wisconsin-geological-and-natural-history-survey/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://www.uwex.edu/wgnhs/&#34; target=&#34;_blank&#34;&gt;Wisconsin Geological and Natural History Survey&lt;/a&gt; has a well organized, appealing website.  Their data is easy to find although there is not much GIS data available.&lt;/p&gt;
&lt;p&gt;Although because I am more interested in sample data sets than anything, the &lt;a href=&#34;http://www.uwex.edu/wgnhs/gis.htm&#34; target=&#34;_blank&#34;&gt;GIS data&lt;/a&gt; they do have–statewide geologic map; pleistocene geology, precambrian geology, quaternary geology, (surficial?) geology and bedrock geology for various counties–may actually be a great reference.  Other than the statewide geologic map, the data is available on a per-publication basis.&lt;/p&gt;
&lt;p&gt;Some other data is available in the &lt;a href=&#34;http://www.uwex.edu/wgnhs/wofrs.htm&#34; target=&#34;_blank&#34;&gt;open-file reports&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;They also have a &lt;a href=&#34;http://www.uwex.edu/wgnhs/wcrs.htm&#34; target=&#34;_blank&#34;&gt;well contructor&amp;rsquo;s reports CD&lt;/a&gt; available for purchase, albeit only scanned images of the wells and a very simple database.&lt;/p&gt;
&lt;p&gt;Other .pdfs are also available of various &lt;a href=&#34;http://www.uwex.edu/wgnhs/sample.htm&#34; target=&#34;_blank&#34;&gt;state-wide maps&lt;/a&gt; and for various open-file reports.&lt;/p&gt;
&lt;p&gt;I found some interesting things while reviewing the data I downloaded.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;There is minimal attribution on the data–enough to symbolize it.&lt;/li&gt;
&lt;li&gt;Dip &amp;amp; Strike triangles are captured as points with attribution of the horizontal azimuth and inclination.&lt;/li&gt;
&lt;li&gt;One item I found odd at first but quickly grew to appreciate is that they provide a georeferenced .sid of  each plate.  This allows you to directly compare the digital data to the final cartographic product.  Think this may be a keeper of an idea.&lt;/li&gt;
&lt;/ol&gt;
</description>
    </item>
    
    <item>
      <title>ArcGIS Ideas</title>
      <link>https://maprantala.com/2010/07/14/arcgis-ideas/</link>
      <pubDate>Wed, 14 Jul 2010 14:20:47 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/14/arcgis-ideas/</guid>
      <description>&lt;p&gt;Ok, maybe I have been hiding under a rock, but just saw this is a post from &lt;a href=&#34;http://www.spatiallyadjusted.com/&#34; target=&#34;_blank&#34;&gt;James Fee&amp;rsquo;s Spatially Adjusted blog&lt;/a&gt;.  ESRI has a public suggestion box called  &lt;a href=&#34;http://ideas.arcgis.com/&#34; target=&#34;_blank&#34;&gt;ArcGIS Ideas&lt;/a&gt; where users can submit suggestions for ESRI.  One thing I like is that it is open for other users to see and comment.  Not sure how responsive ESRI will be but at least it gives us a place to vent.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Iowa Geological Survey</title>
      <link>https://maprantala.com/2010/07/14/iowa-geological-survey/</link>
      <pubDate>Wed, 14 Jul 2010 13:01:47 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/14/iowa-geological-survey/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://www.igsb.uiowa.edu/&#34; target=&#34;_blank&#34;&gt;Iowa Geological Survey&lt;/a&gt;has a lot of data available to download &lt;a href=&#34;http://www.igsb.uiowa.edu/webapps/nrgislibx/&#34; target=&#34;_blank&#34;&gt;here&lt;/a&gt;.  PDF versions of many of their publications can be found in their &lt;a href=&#34;http://www.igsb.uiowa.edu/webapps/gsbpubs/&#34; target=&#34;_blank&#34;&gt;List of Publications&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Their GIS data is minimally attributed for the most part, their public wells data set did have a more robust attribution scheme.  One cool feature I found in the wells data is that they provide a hyper-link for many features to an &lt;a href=&#34;http://www.igsb.uiowa.edu/webapps/geosam/Scripts/geocard.asp?wnumber=43873&#34; target=&#34;_blank&#34;&gt;on-line site record&lt;/a&gt;.  Found both shapefiles and file geodatabases in the samples I downloaded.&lt;/p&gt;
&lt;p&gt;More interestingly, I opened up their Bedrock Geological Map and noticed something odd to me.  See the bulls-eye just NW of center?  That, even to a non-geologist like me, does not look too geologic.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/07/bedrockgeologyrelief.jpg&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;Turns out it is related to a meteorite impact known as the &lt;a href=&#34;http://en.wikipedia.org/wiki/Manson_crater&#34; target=&#34;_blank&#34;&gt;Manson Crater&lt;/a&gt;, once thought to be The Dinosaur Killer until it was determined to be too old.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Entering a Null Value in VB.Net DateTimePicker</title>
      <link>https://maprantala.com/2010/07/13/entering-a-null-value-in-vb.net-datetimepicker/</link>
      <pubDate>Tue, 13 Jul 2010 16:26:45 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/13/entering-a-null-value-in-vb.net-datetimepicker/</guid>
      <description>&lt;p&gt;While working on a VB.Net form to query a database that includes an optional date range query, I decided I wanted to display a datetimepicker with a blank value by default and then, if the user sets a date show the date.  By default, a datetimepicker can not have a Null date, so I went a&amp;rsquo;Googling and found this post, &lt;a href=&#34;http://dotnetref.blogspot.com/2009/03/setting-datetimepicker-to-blank-value.html&#34; target=&#34;_blank&#34;&gt;.NET Reference: Setting the DateTimePicker to a Blank Value&lt;/a&gt;,that had exactly the technique I wanted.&lt;/p&gt;
&lt;p&gt;Basically, I set the datetimepicker&amp;rsquo;s CustomFormat to a space (&#39; &amp;lsquo;) when I want it to be Null and then when the user makes a selection, set the custom format to the date format I wanted to display.    This is the sample code I found:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Private Sub ToDateField_ValueChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) _
   Handles ToDateField.ValueChanged
     Me.ToDateField.Format = Windows.Forms.DateTimePickerFormat.Custom
     Me.ToDateField.CustomFormat = &amp;quot;M/dd/yyyy&amp;quot;
End Sub
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To let the user delete the date they entered, I add this subroutine that handles the KeyDown event for the datetimepicker. If the user hits delete or backspace, I set the format back to my null CustomFormat.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Private Sub ClearDates_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) _
 Handles ToDateField.KeyDown

 If (e.KeyCode = Windows.Forms.Keys.Delete) Or (e.KeyCode = Windows.Forms.Keys.Back) Then
 Dim mDateTimePicker As Windows.Forms.DateTimePicker
          mDateTimePicker = TryCast(sender, Windows.Forms.DateTimePicker)
          If Not (mDateTimePicker Is Nothing) Then
               mDateTimePicker.CustomFormat = &amp;quot; &amp;quot;
          End If
End If
End Sub
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;When building my SQL statement, I check the .CustomFormat property to determine whether or not to include a condition for the data:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;If Not (Me.ToDateField.CustomFormat = &amp;quot; &amp;quot;) Then
 &#39;Code here to add to my SQL statement
 End If
&lt;/code&gt;&lt;/pre&gt;&lt;div id=&#34;geo-post-87&#34; class=&#34;geo geo-post&#34; style=&#34;display: none&#34;&gt;
  &lt;span class=&#34;latitude&#34;&gt;&lt;/span&gt;&lt;span class=&#34;longitude&#34;&gt;&lt;/span&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>South Dakota Geological Survey</title>
      <link>https://maprantala.com/2010/07/13/south-dakota-geological-survey/</link>
      <pubDate>Tue, 13 Jul 2010 12:33:07 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/13/south-dakota-geological-survey/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://www.sdgs.usd.edu/&#34; target=&#34;_blank&#34;&gt;South Dakota Geological Survey&lt;/a&gt; website provides some good base data–imagery, DRGs, DEMs, and DLGs.  There is a searchable database of &lt;a href=&#34;http://www.sddenr.net/core/&#34; target=&#34;_blank&#34;&gt;core cuttings&lt;/a&gt; and the &lt;a href=&#34;http://arcgis.sd.gov/server/sdgis/Data.aspx&#34; target=&#34;_blank&#34;&gt;state data server&lt;/a&gt;  has bedrock data for the eastern portion of the state and a statewide layer, presumably surficial geology, called geology.  Quad-based geological maps are also available (PDF format) in the &lt;a href=&#34;http://www.sdgs.usd.edu/publications/index.html&#34; target=&#34;_blank&#34;&gt;Publications and Maps&lt;/a&gt; section.  The data I downloaded was in shapefile format with minimal attribution.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>North Dakota Geological Survey</title>
      <link>https://maprantala.com/2010/07/12/north-dakota-geological-survey/</link>
      <pubDate>Mon, 12 Jul 2010 13:53:28 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/12/north-dakota-geological-survey/</guid>
      <description>&lt;p&gt;Took a quick look at the &lt;a href=&#34;https://www.dmr.nd.gov/ndgs/&#34; target=&#34;_blank&#34;&gt;North Dakota Geological Survey&amp;rsquo;s website&lt;/a&gt; for GIS data.&lt;/p&gt;
&lt;p&gt;The only data I found served directly from their website was &lt;a href=&#34;https://www.dmr.nd.gov/ndgs/surfacegeo/surfacemapsnew.asp&#34; target=&#34;_blank&#34;&gt;surface geology map&lt;/a&gt; .pdfs for some 24k and 100k maps.  Also available is a search for &lt;a href=&#34;https://www.dmr.nd.gov/oilgas/findwellsvw.asp&#34; target=&#34;_blank&#34;&gt;Oil &amp;amp; Gas wells&lt;/a&gt; although I did not see the data was downloadable.  Some other &lt;a href=&#34;https://www.dmr.nd.gov/ndgs/Publication_List/contentsnew.asp&#34; target=&#34;_blank&#34;&gt;publications&lt;/a&gt; have .pdfs that can be downloaded.&lt;/p&gt;
&lt;p&gt;The  &lt;a href=&#34;http://web.apps.state.nd.us/imf/sites/hubexplorer/jsp/index.jsp&#34; target=&#34;_blank&#34;&gt;North Dakota Hub Explorer&lt;/a&gt; serves as the state&amp;rsquo;s official data portal including for GIS data.  The downloadable data includes bedrock geology, surface geology, and contours.  Interestingly, the site allows you to choose from 7 different coordinate systems and 27 different file formats including several AutoCad, ESRI, MapInfo, and KML.  The data I looked at had more attribution than the bare minimum shown on a hard-copy map.  Bedrock data, for example, had additional lithology.&lt;/p&gt;
&lt;p&gt;Even though I appeared to be getting a &lt;em&gt;Request is complex&lt;/em&gt; error message, their system functioned very well, you step your way through a few selections and a few minutes later you receive an email providing a link to start a download of your compressed data.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ESRI releases Service ArcGIS 9.3.1 Pack 2</title>
      <link>https://maprantala.com/2010/07/12/esri-releases-service-arcgis-9.3.1-pack-2/</link>
      <pubDate>Mon, 12 Jul 2010 12:36:49 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/12/esri-releases-service-arcgis-9.3.1-pack-2/</guid>
      <description>&lt;p&gt;Right before the Users Conference, ESRI has released &lt;a href=&#34;http://blogs.esri.com/Dev/blogs/arcgisdesktop/archive/2010/07/09/ArcGIS-Desktop-9.3.1-Service-Pack-2.aspx&#34; target=&#34;_blank&#34;&gt;ArcGIS Desktop 9.3.1 Service Pack&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Haven&amp;rsquo;t had a chance to see what bugs this addresses yet.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>AASG</title>
      <link>https://maprantala.com/2010/07/09/aasg/</link>
      <pubDate>Fri, 09 Jul 2010 19:49:51 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/09/aasg/</guid>
      <description>&lt;p&gt;I was looking for links to all the State Geological Surveys and found the Association of American State Geologists (AASG) &lt;a href=&#34;http://www.stategeologists.org/&#34; target=&#34;_blank&#34;&gt;Homepage&lt;/a&gt; to have exactly what I needed.&lt;/p&gt;
&lt;p&gt;I hope to build some sort of inventory of data samples available.  If I do one a day, I can be done in 10 weeks, or about 3 months.&lt;/p&gt;
&lt;p&gt;What I will find the most useful is data distribution methods and data structures.&lt;/p&gt;
&lt;p&gt;The USGS has a  &lt;a href=&#34;http://maps.ngmdb.us/dataviewer/&#34; target=&#34;_blank&#34;&gt;sample web application&lt;/a&gt; and it includes statewide data for four states–Arizona, Idaho, Oregon and Washington, so those, along with Illinois and the states that border Minnesota will be among the first I take a look at.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Python emailer</title>
      <link>https://maprantala.com/2010/07/09/python-emailer/</link>
      <pubDate>Fri, 09 Jul 2010 17:20:38 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/09/python-emailer/</guid>
      <description>&lt;p&gt;So I have a nightly process that runs and I, being the lazy programmer I am, didn&amp;rsquo;t want to bother checking a log file each morning to see how it went. The natural answer is to have the results emailed to me because I do have to check my email.&lt;/p&gt;
&lt;p&gt;Since the process is already handled mostly in python, thought I would implement the emailing via python. It was actually simple enough to do–just required figuring out the setting for my SMTP server (actually I didn&amp;rsquo;t figure it our for my work server so I&amp;rsquo;m using my GMail account).&lt;/p&gt;
&lt;p&gt;I first wrote eMailer.py (see code below) and included it in my python path. Now, whenever I want to send code from a python application, it takes two easy lines:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; eMailer
eMailer&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SendMess(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;someoneg@company.com&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Subject&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Text Body&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;emailerpy&#34;&gt;eMailer.py&lt;/h2&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; smtplib
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; email.MIMEMultipart &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; MIMEMultipart
&lt;span style=&#34;color:#f92672&#34;&gt;from&lt;/span&gt; email.MIMEText &lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; MIMEText

fromaddr &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;node.dangles AT gmail.com&amp;#39;&lt;/span&gt;
password &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;myFancyPassword&amp;#39;&lt;/span&gt;
smtpaddr &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;smtp.gmail.com&amp;#39;&lt;/span&gt;
smtpport &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;587&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;SendMess&lt;/span&gt;(toadd, subject, body):

msg &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; MIMEMultipart()
msg[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;From&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; fromaddr
msg[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;To&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; toadd
msg[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Subject&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; subject
msg&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;attach(MIMEText(body, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;plain&amp;#39;&lt;/span&gt;))

text &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; msg&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;as_string()

server &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; smtplib&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;SMTP(smtpaddr, smtpport)
server&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ehlo()
server&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;starttls()
server&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ehlo()
server&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;login(fromaddr, password)

server&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;sendmail(fromaddr, toadd, text)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Hogeweg: ArcGIS Editor for OpenStreetMap</title>
      <link>https://maprantala.com/2010/07/07/hogeweg-arcgis-editor-for-openstreetmap/</link>
      <pubDate>Wed, 07 Jul 2010 19:10:35 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/07/hogeweg-arcgis-editor-for-openstreetmap/</guid>
      <description>&lt;p&gt;As someone who lives in the boon-docks whose street (both my current and previous one) does not appear in the data for either &lt;a href=&#34;http://www.navteq.com/&#34; target=&#34;_blank&#34;&gt;NAVTEQ&lt;/a&gt; or &lt;a href=&#34;http://www.teleatlas.com/&#34; target=&#34;_blank&#34;&gt;TeleAtlas&lt;/a&gt; and someone who used both of those data sets extensively in his previous job, I&amp;rsquo;ve watched OpenStreetMap for awhile, although have not contributed.&lt;/p&gt;
&lt;p&gt;Marten Hogeweg, &lt;span class=&#34;bio&#34;&gt;ArcGIS Server Geoportal Extension Product Manager, ESRI announce in his blogs an &lt;a href=&#34;http://martenhogeweg.blogspot.com/2010/07/announcing-arcgis-editor-for.html&#34; target=&#34;_blank&#34;&gt;ArcGIS Editor for OpenStreetMap&lt;/a&gt;&lt;/span&gt;.  Sounds like a great idea, giving GIS professionals–some whom have the source materials the ability to easily contribute should only help the project.&lt;/p&gt;
&lt;p&gt;Unfortunately, it is only available at 10.0 but that gives me another reason to install it on a virtual machine and start playing more.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>NED Processing in Python and Geoprocessing</title>
      <link>https://maprantala.com/2010/07/07/ned-processing-in-python-and-geoprocessing/</link>
      <pubDate>Wed, 07 Jul 2010 14:05:20 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/07/ned-processing-in-python-and-geoprocessing/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;http://www.usgs.gov/&#34; target=&#34;_blank&#34;&gt;USGS&lt;/a&gt; updated a significant portion of &lt;a href=&#34;http://ned.usgs.gov/&#34; target=&#34;_blank&#34;&gt;NED&lt;/a&gt; data for my state in June.  I recently downloaded the updates, processed them–projecting and converting the elevations from meters to feet–using python and geoprocessing.  My python skills are still pretty crude but I was able to get the job done.&lt;/p&gt;
&lt;p&gt;One of the benefits of working for the public sector is that I can more freely publish code without worrying about &amp;lsquo;trade secrets&amp;rsquo; or what have you so I thought I would put my code out for anyone to see, maybe someone will find it useful.  It is split into two separate files, mostly because I used &lt;a href=&#34;http://webhelp.esri.com/arcgisdesktop/9.2/index.cfm?TopicName=An_overview_of_ModelBuilder&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;Model Builder&lt;/a&gt; to generate the main processing chunk of code (Project_Reclassify.py) and another script to control looping, etc. The code isn&amp;rsquo;t pretty and you&amp;rsquo;ll see the results of my development process with two subroutines in LaunchScript.py that could really be one.&lt;/p&gt;
&lt;h3 id=&#34;heading&#34;&gt;&lt;/h3&gt;
&lt;h3 id=&#34;launchscriptpy&#34;&gt;LaunchScript.py&lt;/h3&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; Project_Reclassify

mConversion &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;3.28084&amp;#34;&lt;/span&gt;
mProjection &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;PROJCS[&amp;#39;NAD_1983_UTM_Zone_15N&amp;#39;,GEOGCS[&amp;#39;GCS_North_American_1983&amp;#39;,DATUM[&amp;#39;D_North_American_1983&amp;#39;,SPHEROID[&amp;#39;GRS_1980&amp;#39;,6378137.0,298.257222101]],PRIMEM[&amp;#39;Greenwich&amp;#39;,0.0],UNIT[&amp;#39;Degree&amp;#39;,0.0174532925199433]],PROJECTION[&amp;#39;Transverse_Mercator&amp;#39;],PARAMETER[&amp;#39;False_Easting&amp;#39;,500000.0],PARAMETER[&amp;#39;False_Northing&amp;#39;,0.0],PARAMETER[&amp;#39;Central_Meridian&amp;#39;,-93.0],PARAMETER[&amp;#39;Scale_Factor&amp;#39;,0.9996],PARAMETER[&amp;#39;Latitude_Of_Origin&amp;#39;,0.0],UNIT[&amp;#39;Meter&amp;#39;,1.0]]&amp;#34;&lt;/span&gt;
mCellSize &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;10&amp;#34;&lt;/span&gt;

&lt;span style=&#34;color:#75715e&#34;&gt;#Project_Reclassify.Process(&amp;#34;C:\mgs\Projects\NED_10m\n44w092\grdn44w092_13&amp;#34;, mProjection, mConversion,&amp;#34;C:\mgs\Projects\NED_10m\n44w092\try30&amp;#34;,mCellSize)&lt;/span&gt;

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;CallIt&lt;/span&gt; (inDir,inGrid,outGrid):
fullinFN &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inDir&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;+inGrid&lt;/span&gt;
fulloutFN &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;C:\mgs\Projects\NED_10m\Output&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;+outGrid&lt;/span&gt;
tmpGridFN &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;c:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\t&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;emp&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\t&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;outGrid
Project_Reclassify&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Process(fullinFN, mProjection, mConversion,fulloutFN,mCellSize,tmpGridFN)

&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;CallIt2&lt;/span&gt; (inGrd,inoutGrd):
outDir &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;C:\mgs\Projects\NED_10m&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;\&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt; + inGrd + &amp;#39;&lt;/span&gt;\&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39; + inGrd&lt;/span&gt;

outGrd &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;grd&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;inGrd&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;_13&amp;#39;&lt;/span&gt;

CallIt(outDir,outGrd,inoutGrd)

&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n44w092&amp;#34;,&amp;#34;LaCrosse_W&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n44w093&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;MasonCity_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n44w094&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;MasonCity_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n44w095&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fairmont_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n44w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fairmont_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n44w097&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;SiouxFalls_E&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n45w092&amp;#34;,&amp;#34;EauClaire_W&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n45w093&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;StPaul_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n45w094&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;StPaul_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n45w095&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NewUlm_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n45w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;NewUlm_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n45w097&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Watertown_E&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n46w093&amp;#34;,&amp;#34;Stillwater_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n46w094&amp;#34;,&amp;#34;Stillwater_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n46w095&amp;#34;,&amp;#34;StCloud_E&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n46w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;StCloud_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n46w097&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Milbank_E&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n47w092&amp;#34;,&amp;#34;Ashland_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n47w093&amp;#34;,&amp;#34;Duluth_E&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n47w094&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Duluth_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n47w095&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brainerd_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n47w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Brainerd_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n47w097&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Fargo_E&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w090&amp;#34;,&amp;#34;Hancock_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w091&amp;#34;,&amp;#34;TwoHarbors_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w092&amp;#34;,&amp;#34;TwoHarbors_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w093&amp;#34;,&amp;#34;Hibbing_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w094&amp;#34;,&amp;#34;Hibbing_W&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n48w095&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bemidji_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n48w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Bemidji_W&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n48w097&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;GrandForks_E&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n48w098&amp;#34;,&amp;#34;GrandForks_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w090&amp;#34;,&amp;#34;ThunderBay_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w091&amp;#34;,&amp;#34;Quetico_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w092&amp;#34;,&amp;#34;Quetico_W&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w093&amp;#34;,&amp;#34;InternationFalls_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w094&amp;#34;,&amp;#34;InternationFalls_W&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n49w095&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Roseau_E&amp;#34;&lt;/span&gt;)
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n49w096&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Roseau_W&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n49w097&amp;#34;,&amp;#34;ThiefRiverFalls_E&amp;#34;)&lt;/span&gt;
CallIt2(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n49w098&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ThiefRiverFalls_W&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n50w095&amp;#34;,&amp;#34;Kenora_E&amp;#34;)&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;#CallIt2(&amp;#34;n50w096&amp;#34;,&amp;#34;Kenora_W&amp;#34;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id=&#34;projectreclassifypy&#34;&gt;Project.Reclassify.py&lt;/h3&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;# Import system modules&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; sys&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; string&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; os&lt;span style=&#34;color:#f92672&#34;&gt;,&lt;/span&gt; arcgisscripting

&lt;span style=&#34;color:#75715e&#34;&gt;# Create the Geoprocessor object&lt;/span&gt;
gp &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; arcgisscripting&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;create()

&lt;span style=&#34;color:#75715e&#34;&gt;# Check out any necessary licenses&lt;/span&gt;
gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;CheckOutExtension(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;spatial&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#75715e&#34;&gt;# Load required toolboxes...&lt;/span&gt;
gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddToolbox(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/Program Files/ArcGIS/ArcToolbox/Toolboxes/Spatial Analyst Tools.tbx&amp;#34;&lt;/span&gt;)
gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;AddToolbox(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;C:/Program Files/ArcGIS/ArcToolbox/Toolboxes/Data Management Tools.tbx&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#75715e&#34;&gt;# Script arguments...&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;Process&lt;/span&gt;( inInputRaster, inOutputCoord, inConversionFactor, inOutputRaster, inCellSize, intempRasterFN):
Input_Raster &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inInputRaster &lt;span style=&#34;color:#75715e&#34;&gt;#sys.argv[1]&lt;/span&gt;
Output_Coordinate_System &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inOutputCoord &lt;span style=&#34;color:#75715e&#34;&gt;#sys.argv[3]&lt;/span&gt;
Input_raster_or_constant_value_2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inConversionFactor &lt;span style=&#34;color:#75715e&#34;&gt;#sys.argv[4]&lt;/span&gt;
Output_CellSize &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inCellSize

&lt;span style=&#34;color:#75715e&#34;&gt;#if Input_raster_or_constant_value_2 == &amp;#39;#&amp;#39;:&lt;/span&gt;
&lt;span style=&#34;color:#75715e&#34;&gt;# Input_raster_or_constant_value_2 = &amp;#34;3.28084&amp;#34; # provide a default value if unspecified&lt;/span&gt;

Output_raster &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; inOutputRaster

&lt;span style=&#34;color:#75715e&#34;&gt;# Local variables...&lt;/span&gt;
Temp_Raster &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; intempRasterFN

&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; Input_Raster
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; Temp_Raster
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; Output_Coordinate_System
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; inCellSize

&lt;span style=&#34;color:#75715e&#34;&gt;# Process: Project Raster...&lt;/span&gt;
gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ProjectRaster_management(Input_Raster, Temp_Raster, Output_Coordinate_System, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;CUBIC&amp;#34;&lt;/span&gt;, Output_CellSize, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; Input_raster_or_constant_value_2
&lt;span style=&#34;color:#66d9ef&#34;&gt;print&lt;/span&gt; Output_raster

&lt;span style=&#34;color:#75715e&#34;&gt;# Process: Times...&lt;/span&gt;
gp&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Times_sa(Temp_Raster, Input_raster_or_constant_value_2, Output_raster)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>Sticky Move Tolerance</title>
      <link>https://maprantala.com/2010/07/01/sticky-move-tolerance/</link>
      <pubDate>Thu, 01 Jul 2010 16:51:42 -0500</pubDate>
      <guid>https://maprantala.com/2010/07/01/sticky-move-tolerance/</guid>
      <description>&lt;p&gt;While I am pretty experienced in editing data in previous generations of ESRI&amp;rsquo;s software, I have not done a lot in ArcGIS. So in my new position where I am supporting a group of geologists who do a lot of data creation in ArcMap, I am learning some of the intricacies of the ArcGIS platform.&lt;/p&gt;
&lt;p&gt;One of the potential gotchas that a coworker informed me about that I was vaguely aware of was the issue of sticky move tolerances. What can happen, when editing existing features, is that each time you select a feature it can easily get moved very slightly if the mouse moves while the feature is selected. While the movement itself may be well within any allowable accuracy requirements, it can make a huge mess if you are working with a shapefile polygon coverage for example.&lt;/p&gt;
&lt;p&gt;ArcMap has a setting, Sticky Move Tolerance, that helps prevent these tiny, accidental moving of features.  A feature will not be moved until the mouse moves at least as many screen pixels as this setting.  The default setting is 0, disabling this feature.&lt;/p&gt;
&lt;p&gt;This setting can be set changed under Options on the Editor Toolbar.
&lt;img src=&#34;https://maprantala.com/images/2010/07/setting.jpg&#34; alt=&#34;Settings&#34;&gt;&lt;/p&gt;
&lt;p&gt;The Sticky move tolerance is on the General tab.  In this example, I have my setting at 25 pixels which may be a bit high but I do not do a lot of data editing myself so it is workable.  The downside of having it set this high is if I want to move a feature just a tiny bit, I have to first drag the mouse relatively far away and then bring it tighter into where the feature is.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://maprantala.com/images/2010/07/options.jpg?resize=344%2C341g&#34; alt=&#34;Options&#34;&gt;&lt;/p&gt;
&lt;p&gt;Not sure how well this is documented although it can be found &lt;a href=&#34;https://webhelp.esri.com/arcgisdesktop/9.3/index.cfm?TopicName=Moving_features&#34; target=&#34;_blank&#34;&gt;in the help system.&lt;/a&gt;&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ArcMap-Excel Join Error</title>
      <link>https://maprantala.com/2010/05/28/arcmap-excel-join-error/</link>
      <pubDate>Fri, 28 May 2010 02:02:37 -0500</pubDate>
      <guid>https://maprantala.com/2010/05/28/arcmap-excel-join-error/</guid>
      <description>&lt;p&gt;Came across a new ArcMap bug today. A staff member was trying to join an Excel 2007 file (.xlsx) to a point shapefile in ArcMap and it did not appear to be working. She only had Office 2003 on her machine so I tried it on my spanking new machine that has 2007 installed. Same result–the fields get appended but they are all blank.&lt;/p&gt;
&lt;p&gt;I discovered, however, that when I had the table open, if I switched form showing ALL records to only the selected, Poof!!! The values filled in. From there I was able to successfully export the data to a new shapefile that always showed the values.&lt;/p&gt;
&lt;p&gt;I have an inkling that the file name, which contained space and other special characters, may have been a factor.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;August 11, 2010 Addendum:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I was just working with some more and, after joining a table to an Excel table, having all the fields look blank, I discovered that if I close and then re-open the table all looks good–all fields have values.&lt;/p&gt;
&lt;p&gt;Another problem I had is that even after successfully joining a table to the Excel table and creating an XY Event Theme from it, I was unsuccessful in exporting it to either a shapefile or a personal geodatabase feature class.  My personal opinion at this point would be to convert the Excel file to a different format before working with it in ArcGIS.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Geology Information Systems</title>
      <link>https://maprantala.com/2010/05/24/geology-information-systems/</link>
      <pubDate>Mon, 24 May 2010 02:52:24 -0500</pubDate>
      <guid>https://maprantala.com/2010/05/24/geology-information-systems/</guid>
      <description>&lt;p&gt;In the last couple months, I&amp;rsquo;ve had a bit of an eye-opening about Geography. People actually trained in geography may implicitly understand this but I, with my Accounting degree, have spent the last 16 years &amp;lsquo;doing&amp;rsquo; GIS without realizing the foundation of geography–geology. I picked up enough geography to understand some of the inter-relationships between people and the lands they live on.&lt;/p&gt;
&lt;p&gt;But what I didn&amp;rsquo;t pick up on was how the lands we live on are formed. Maybe it is a moot point–how physical geography is arrived at doesn&amp;rsquo;t matter, just how we react to it. But, and now working for a Geological Survey, I better have this opinion, a better understanding of what our geology is and how it was formed really does form the foundation for the geography.&lt;/p&gt;
&lt;p&gt;Two examples. First, in talking with my new supervisor, he was talking about how, because of the geology in the southeast part of the state, they have a lot of water quality issues–the water tends to have sulfur in it. With the recent interest in alternative energy sources, and in this case ethanol plants water quality is a concern when deciding where to build the plants because they require a considerable amount of water. For some reason there have been plants placed in this part of the state and they are having some problems finding sufficient water.&lt;/p&gt;
&lt;p&gt;The second, and I&amp;rsquo;m not sure that this is actually fact or just a theory but it is an interesting idea, was something I read in Malcolm Gladwell&amp;rsquo;s book &lt;em&gt;Outliers&lt;/em&gt;. In the book, it was suggested that there was an almost epidemic of feuds, a la Hatfield-McCoy, in part of the US largely due to the geology of a portion of the country. The areas that relied on a herding economy developed a clannish &amp;lsquo;code of honor&amp;rsquo; that led to these long-term feuds. While I understood that physical geography effects human behavior I hadn&amp;rsquo;t taken the mental step to link geology to physical geography.&lt;/p&gt;
&lt;p&gt;Pretty silly and probably obvious oversight.&lt;/p&gt;
&lt;p&gt;And to think, I use to think the &amp;lsquo;G&amp;rsquo; in GIS should really stand for Geometry. Humph!&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Measuring distance from a point to a line segment in Python</title>
      <link>https://maprantala.com/2010/05/16/measuring-distance-from-a-point-to-a-line-segment-in-python/</link>
      <pubDate>Sun, 16 May 2010 17:14:23 -0500</pubDate>
      <guid>https://maprantala.com/2010/05/16/measuring-distance-from-a-point-to-a-line-segment-in-python/</guid>
      <description>&lt;p&gt;I recently had the need to calculate the distance from a point (address point) to a polyline (street segment) and wanted to avoid using any additional libraries because it was being done for an external client. Ok, I actually used arcgisscripting for reading the data but that lacked, from what I could tell, the fine-detail granularity of measuring distance between individual geometries.&lt;/p&gt;
&lt;p&gt;But since the only spatial operations I needed were to measure the distance between two points and the distance between a point and polyline, I decided to just do it via brute force. The datasets being processed were not huge so it made this feasible.&lt;/p&gt;
&lt;p&gt;Measuring point-to-point distance was easy enough. And while I knew I could work through the details of measuring the distance between a point and polyline, I decided NOT to re-invent the wheel if I did not have to. Google did not come up with any direct answers but I did come across this &lt;a href=&#34;http://local.wasp.uwa.edu.au/%7Epbourke/geometry/pointline/&#34; target=&#34;_blank&#34;&gt;post&lt;/a&gt; from &lt;a href=&#34;http://local.wasp.uwa.edu.au/%7Epbourke/&#34; target=&#34;_blank&#34;&gt;Paul Bourke&lt;/a&gt; at the  &lt;a href=&#34;http://wasp.uwa.edu.au/&#34; target=&#34;_blank&#34;&gt;University of Western Australia&lt;/a&gt; about measuring the distance between a point and a line segment. A polyline is just a series of line segments so I used it as the basis of my measurement–I just loop through all the consecutive vertice pairs, using the minimum distance found.&lt;/p&gt;
&lt;p&gt;Paul did not have a python implementation included, so I went ahead and created my own from his information.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;lineMagnitude&lt;/span&gt; (x1, y1, x2, y2):
    lineMagnitude &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; math&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;sqrt(math&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;pow((x2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; x1), &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;)&lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; math&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;pow((y2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; y1), &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;))
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; lineMagnitude

&lt;span style=&#34;color:#75715e&#34;&gt;#Calc minimum distance from a point and a line segment (i.e. consecutive vertices in a polyline).&lt;/span&gt;
&lt;span style=&#34;color:#66d9ef&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;DistancePointLine&lt;/span&gt; (px, py, x1, y1, x2, y2):
    &lt;span style=&#34;color:#75715e&#34;&gt;#http://local.wasp.uwa.edu.au/~pbourke/geometry/pointline/source.vba&lt;/span&gt;
    LineMag &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; lineMagnitude(x1, y1, x2, y2)

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; LineMag &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0.00000001&lt;/span&gt;:
        DistancePointLine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;9999&lt;/span&gt;
        &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; DistancePointLine

    u1 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; (((px &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; x1) &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (x2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; x1)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; ((py &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; y1) &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (y2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; y1)))
    u &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; u1 &lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt; (LineMag &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; LineMag)

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (u &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0.00001&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;or&lt;/span&gt; (u &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;):
        &lt;span style=&#34;color:#75715e&#34;&gt;#// closest point does not fall within the line segment, take the shorter distance&lt;/span&gt;
        &lt;span style=&#34;color:#75715e&#34;&gt;#// to an endpoint&lt;/span&gt;
        ix &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; lineMagnitude(px, py, x1, y1)
        iy &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; lineMagnitude(px, py, x2, y2)
        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; ix &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; iy:
            DistancePointLine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; iy
        &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
            DistancePointLine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; ix
    &lt;span style=&#34;color:#66d9ef&#34;&gt;else&lt;/span&gt;:
        &lt;span style=&#34;color:#75715e&#34;&gt;# Intersecting point is on the line, use the formula&lt;/span&gt;
        ix &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; x1 &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; u &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (x2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; x1)
        iy &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; y1 &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; u &lt;span style=&#34;color:#f92672&#34;&gt;*&lt;/span&gt; (y2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; y1)
        DistancePointLine &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; lineMagnitude(px, py, ix, iy)

    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; DistancePointLine
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>My Favorite Avenue Snippet Ever</title>
      <link>https://maprantala.com/2010/05/16/my-favorite-avenue-snippet-ever/</link>
      <pubDate>Sun, 16 May 2010 16:33:30 -0500</pubDate>
      <guid>https://maprantala.com/2010/05/16/my-favorite-avenue-snippet-ever/</guid>
      <description>&lt;p&gt;I worked in Avenue for many years but do not expect to do too much more. Before my Avenue skills erode to nothing, thought I would share my favorite Avenue snippet. Really, it involves two &amp;lsquo;function&amp;rsquo; scripts that clients scripts can use.&lt;/p&gt;
&lt;p&gt;What I got use to doing is instead of using a mess of global variables is using one global variable–a dictionary–that was used to store what essentially became global variables. The main advantage of doing this is that I started storing the parameters passed to each script as a global variable named after the script. This came in EXTREMELY useful for debugging purposes because when I was having trouble with a script I could write out my global dictionary to an ODB file at the beginning of that script, thereby storing the application&amp;rsquo;s state prior to the problem.&lt;/p&gt;
&lt;p&gt;The first script, MyApplication_Routine_AddSelfDict, is used to add/modify a dictionary entry:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;theScript = self.get(0)
theSelf = self.get(1)

if (_MyApplication_SelfDict.is(Dictionary).not) then
  _MyApplication_SelfDict = dictionary.make(25)
end

if (self &amp;lt;&amp;gt; nil) then
  _MyApplication_SelfDict.add(theScript,theSelf)
  _MyApplication_SelfDict.set(theScript,theSelf)
end
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;The second script, MyApplication_Routine_GetSelfDict,  is used to retrieve a value from the global dictionary.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;if (_MyApplication_SelfDict.is(Dictionary).not) then
  _MyApplication_SelfDict = dictionary.make(25)
end

return (_MyApplication_SelfDict.get(self))
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Then I can have client scripts first add an entry (primary key = script name)to the global dictionary storing the parameters passed in (self).  Then I set a local variable to the entry just added.   Then, if I need to debug later, I can throw an exit (shown in red) into the script, run the process and after it exits, I can step through the script and pull the parameters passed in from the global dictionary.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;If (self&amp;lt;&amp;gt;nil) then
  av.run(&amp;quot;MyApplication_Routine_AddSelfDict&amp;quot;,{&amp;quot;MyApplication_ClientScript&amp;quot;,self})
End

theSelf = av.run(&amp;quot;MyApplication_Routine_GetSelfDict&amp;quot;,&amp;quot;MyApplication_ClientScript&amp;quot;)

&#39;**** The following EXIT is added for debugging purposes.  
&#39;This gets temporarily added so I can capture &#39;the application  state.
&#39;After running the process and getting to this point, I remove the exit and can step 
&#39;through this script.  The snippet above retrieves the parameters as passed into this script.

EXIT
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;And that&amp;rsquo;s it.  Took me several years to refine this technique–for a long time I just stuck a check in at the beginning of each script to see if there were any parameters passed and if so, store them in a separate global.  But what I like abut this is I can write the whole global dictionary out to an ODB, quit out of ArcView and then return to the project, read in the ODB and reset my global dictionary and pick up from where I left off.&lt;/p&gt;
&lt;p&gt;The one addition that I added later was to remove entries from the global dictionary once a script ends.  I didn&amp;rsquo;t show it here.&lt;/p&gt;
&lt;p&gt;Having all this data in one global dictionary is probably a horrendous design approach to anyone with an Object-Orientated mindset but, as they say, it got the job done.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Endpoints</title>
      <link>https://maprantala.com/2010/05/15/endpoints/</link>
      <pubDate>Sat, 15 May 2010 13:27:09 -0500</pubDate>
      <guid>https://maprantala.com/2010/05/15/endpoints/</guid>
      <description>&lt;p&gt;I spent almost nine years working for a great company, &lt;a href=&#34;https://www.adc4gis.com/&#34; target=&#34;_blank&#34;&gt;Applied Data Consultants!&lt;/a&gt;, through a variety of roles–spent approximately 3 weeks doing Parcel work as a GIS Tech before I started working in Avenue for my own sanity. After that, spent several years doing various programming tasks including building tools for internal production and application development. The last couple years, I served more of a Consultant role, both for internal and external clients.&lt;/p&gt;
&lt;p&gt;Where one polyline ends, another starts in this case.&lt;/p&gt;
&lt;p&gt;In a couple days, I start my role as Geological Information Specialist at a state agency in Minnesota. I previously worked for the Wisconsin DNR (where I originally &amp;lsquo;discovered&amp;rsquo; GIS) and Pierce County, Wisconsin so I have some governmental experience but I am wondering how I will adapt to the organizational differences.&lt;/p&gt;
</description>
    </item>
    
  </channel>
</rss>
