Apply Element Values (Topographic Production)

Summary

Applies surround element values to target features.

Usage

  • The input layout must be open and active in the ArcGIS Pro project.

  • This tool supports the Guide To Numbered Features element and the Index To Streets element. The elements must have valid source layers. These layers will be used as the output feature class when updating fields values.

  • All matching features in the target feature class will be updated even if the map surround element does not display all values due to size limitations.

  • Only the visible fields that are calculated automatically from the input map surround will be displayed as a source field option in the Field Map parameter. If no fields are defined on the element, the tool will not run.

    Note:

    The following fields are calculated automatically:

    • ID Number
    • Grid Reference
  • The following output field types are supported: Long, Short, Big Integer, Float, Double, and Text.

Parameters

LabelExplanationData Type
Input Layout

The layout that contains the map surround element with the values that will be applied to the target feature class.

Layout
Map Surround

The name of the map surround element that contains the values used as a data source.

String
Field Map

The field map that maps the fields from the map surround element to the target feature class.

Value Table

Derived Output

LabelExplanationData Type
Updated Feature Class

The existing dataset where the surround element values will be copied. The default is the Map Surround parameter value's source layer.

Feature Layer

arcpy.topographic.ApplyElementValues(in_layout, map_surround, field_mapping)
NameExplanationData Type
in_layout

The layout that contains the map surround element with the values that will be applied to the target feature class.

Layout
map_surround

The name of the map surround element that contains the values used as a data source.

String
field_mapping
[field_mapping,...]

The field map that maps the fields from the map surround element to the target feature class.

Value Table

Derived Output

NameExplanationData Type
updated_feature_class

The existing dataset where the surround element values will be copied. The default is the map_surround parameter value's source layer.

Feature Layer

Code sample

ApplyElementValues example 1 (stand-alone script)

The following code sample demonstrates how to use the ApplyElementValues function in Python to copy the values from a Guide To Numbered Features surround element to an output feature class.

# Name: ApplyElementValues_sample1.py
# Description: The Apply Element Values tool will calculate fields of numbered features using the Guide To Numbered Features
# map surround and copy the values to an output feature class on disk.

# Import System Modules
import arcpy

# Reference current project on disk
currentProject = arcpy.mp.ArcGISProject(r"C:\Data\ICM.aprx")

# Access the layout
layout = currentProject.listLayouts()[0]

# Calling the Apply Element Values tool to calculate fields of numbered features using the Guide To Numbered Features map surround
arcpy.topographic.ApplyElementValues(in_layout=layout, map_surround="Guide To Numbered Features", field_mapping="'<Auto Calculate Grid Reference>' MGRSValue;'<Auto Generate ID Number>' IDN")
ApplyElementValues example 2 (stand-alone script)

The following code sample demonstrates how to use the ApplyElementValues function in Python to copy the values from an Index To Streets surround element to an output feature class.

# Name: ApplyElementValues_sample2.py
# Description: The Apply Element Values tool will calculate fields of numbered features using the Index To Streets
# map surround and copy the values to an output feature class on disk.

# Import System Modules
import arcpy

# Reference current project on disk
currentProject = arcpy.mp.ArcGISProject(r"C:\Data\ICM.aprx")

# Access the layout
layout = currentProject.listLayouts()[0]

# Calling the Apply Element Values tool to calculate fields of numbered features using the Index To Streets map surround
arcpy.topographic.ApplyElementValues(in_layout=layout, map_surround="Index To Streets", field_mapping="'<Auto Calculate Grid Reference>' MGRSValue")

Environments

This tool does not use any geoprocessing environments.

Licensing information

  • Basic: No
  • Standard: Requires Topographic Mapping
  • Advanced: Requires Topographic Mapping

Related topics