Setting template instructions for python scripts
Template instructions allow products to be more dynamic, allowing them to perform actions during key events like a checkout. There are three types of template instructions controlled by file types: data frame rules, layout rules, and python scripts.
The Python Scripts properties allow custom business logic to be executed on a product. A single python file can be saved as part of template instructions.
- Start ArcMap.ヒント:
If the ArcMap - Getting Started dialog box appears, you can open a new or existing map document. You can also check the Do not show this dialog box in the future check box and click Open.
-
If necessary, open the Product Library window by clicking Customize → Production → Product Library on the main menu.
A tree view of the product library appears.
-
Right-click an existing class, series, or product from the product library tree and choose Properties.
The properties dialog box for the class, series, or product appears.
- Click Template Instructions on the left-hand pane.
-
Click the plus sign (+) next to Python Script.
The Python Script properties appear.
- Click the cell next to File and click the ellipsis (...) that appears.
The Browse For File dialog box appears.
- Click the Storage type drop-down arrow and choose an option:
- File system—If the file is stored in a local or network computer
- Database—If the file is stored in a database
- Click the ellipsis (…) next to the Location field.
The Open dialog box appears.
- Navigate to the python script PY file you want to use.
- Click Open.
The Browse For File dialog box appears with the path to the XML file in the Location field.
- Click OK.
The properties dialog box for the class, series, or product appears.
- Click OK.