Skip to content

Instantly share code, notes, and snippets.

View alexfriant's full-sized avatar

Alex alexfriant

View GitHub Profile
@alexfriant
alexfriant / list_min_scales.py
Last active November 13, 2020 19:40
list the minimum scale values for all layers in an mxd (the don't show out-beyond scale)
#################################################################################
#
# Requirements: You'll need ArcGIS Desktop 10.1 or higher with Python 2.7
#
# If you are publishing an MXD as a map service you might get a warning from
# the Analyze option that some number of layers "draws at all scale ranges".
#
# This script lists all the layers in the MXD you have open and what their
# minimum scale is set at, if at all. Those with '0.0' values have no value set.
#
@alexfriant
alexfriant / set_min_scales.py
Last active July 4, 2023 23:03
set the minimum scale values for all layers in an mxd that don't have minimum scale values already set (the don't show out-beyond scale)
#################################################################################
#
# Requirements: You'll need ArcGIS Desktop 10.1 or higher with Python 2.7
#
# If you are publishing an MXD as a map service you might get a warning from
# the Analyze option that some number of layers "draws at all scale ranges".
#
# This script sets all the layers in the MXD you have open to a minimum scale
# value of your choosing IF a layer's value is not set (indicated by being 0.0).
#