This section details the construction of a Create Map tool, which will allow the end user to generate and export a map using a predefined layer file containing the symbology and a selected polygon feature class, which in turn will contain a count field (Join_Count
) that was created with the Aggregate Crimes tool:
If necessary, open
C:\ArcGIS_Blueprint_Python\ch4\SeattleCrimes.mxd
in ArcMap.Switch to the Layout view so that we can build the structure of the map that will be exported.
Build the layout so that it appears similar to what is shown in the following screenshot:
Double-click on the Title text element to display the properties.
Click on the Size and Position tab and set Element Name to
CrimeTitle
, as shown in the following screenshot. Setting Element Name will enable us to access this element through a Python script that will dynamically set the name based on the user input.From the Catalog window, open the Python development environment...