OBJECTIVE
Objective of this project was to build a complete map, making use of Python/arcpy.
Much of my former (and future) project work consists of updating text elements in numerous maps in ArcMap.
Opening, checking and updating each and every map is tedious and time-consuming.
Therefore, it was my objective to explore and utilize the arcpy mapping module by creating a complete map from scratch.
In addition to it's possibilities, I also encountered it's limitations compared to working within ArcMap directly - which was also part of the learning process.
However, for updating text elements without having to open the mxd or the script, I made use of the ConfigParser class, which will read text passages from a text file and updates the map accordingly. This can be of great use for future project work.
SETUP
- Please open the file "config.conf" in any texteditor and exchange the path to the project ([PATHS] Project) with the respective path on your computer. --> Save the changes.
- To run the script, open your Command Prompt and navigate to the folder in which the project is stored on your computer.
Type the name of the Python script and on second position the name of the configuration file like:
Mapbuilder.py config.conf
After the script was successfully executed, there will be a new mxd "ProjectCopy.mxd" and a PDF "FinalMap.PDF" in your project folder.
• The script was successfully tested using ArcMap 10.6 with Python 2.7 running on Windows 8.1.
If you encounter any difficulties executing the script, please contact me under:
Linda.Menk@stud.sbg.ac.at