ArcGIS Desktop

  • Documentation
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS Desktop

A complete professional GIS

ArcGIS Enterprise

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

ArcMap

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • Extensions

Apply Symbology From Layer

  • Summary
  • Illustration
  • Usage
  • Syntax
  • Code sample
  • Environments
  • Licensing information

Summary

This tool applies the symbology from a layer to the Input Layer. It can be applied to feature, raster, network analysis, TIN, and geostatistical layer files or layers in the ArcMap table of contents. This tool is primarily for use in scripts or ModelBuilder.

Illustration

The Apply Symbology From Layer tool

Usage

  • In model or script use, the Symbology Layer most often comes from a layer file. The Make Feature Layer tool or the Make Raster Layer tool can be used to create a layer to apply symbology. Feature, raster, and TIN layers can also be created by right-clicking the layer in the ArcMap table of contents and clicking Save As Layer File. The layer is then saved in the desired location.

  • The Symbology Layer must match the data type of the Input Layer; for example, a feature layer cannot be applied to a raster layer and vice versa.

  • The Symbology Layer can only be applied to features of the same geometry; for example, a point layer cannot be applied to a polygon layer.

  • The field in the Input Layer that will be displayed must have the same name as that of the corresponding Symbology Layer field. If this field is missing, the output data is drawn with default symbology.

    • You can name a field in the Input Layer to match the Symbology Layer field name using the Make_Feature_Layer tool.
  • 3D properties such as extrusion and offset are not supported with this tool.

  • Symbology methods can be dynamic; for example, the symbology is updated to reflect the characteristics of the Input Layer as shown in the illustration below. In this example, the five class Natural Breaks classification method from the Symbology Layer is applied to the Input Layer and the range values are updated to reflect the Shape_Area values of the Input Layer.

    Example of how

    The following methods are dynamic:

    • Unique values symbology to a feature
      • The unique values are updated to reflect the Input Layer.
      • If you do not want the unique values classification to be updated, then choose the <all other values> default symbol in the Symbology Layer.
    • Graduated color symbology to a feature
      • The range values are updated to the values of the Input Layer.
      • If you do not want your range output to be updated, then choose manual classification.
    • Classified value rendering to a raster
      • The range values are updated to reflect the values of the Input Layer.
      • If you do not want your range output to be updated, then choose manual classification.

Syntax

ApplySymbologyFromLayer_management (in_layer, in_symbology_layer)
ParameterExplanationData Type
in_layer

The layer to which the symbology will be applied.

Feature Layer;Raster Layer; TIN Layer;Network Analysis Layer;Geostatistical Layer
in_symbology_layer

The symbology of this layer is applied to the Input Layer.

Feature Layer; Raster Layer;TIN Layer; Network Analysis Layer;Geostatistical Layer

Code sample

ApplySymbologyFromLayer Example 1 (Python Window)

The following Python window script demonstrates how to use the ApplySymbologyFromLayer function in immediate mode.

import arcpy
arcpy.ApplySymbologyFromLayer_management("sf_points", "sf_points_water.lyr")
ApplySymbologyFromLayer Example 2 (Stand-alone Script)

The following stand-alone script shows how to use the ApplySymbologyFromLayer function in scripting.

# Name: ApplySym.py
# Purpose: apply the symbology from one layer to another

# Import system modules
import arcpy
from arcpy import env

# Set the current workspace
env.workspace = "C:/data"

# Set layer to apply symbology to
inputLayer = "sf_points.lyr"

# Set layer that output symbology will be based on
symbologyLayer = "water_symbols_pnt.lyr"

# Apply the symbology from the symbology layer to the input layer
arcpy.ApplySymbologyFromLayer_management (inputLayer, symbologyLayer)

Environments

  • Auto Commit
  • Current Workspace

Licensing information

  • ArcGIS Desktop Basic: Yes
  • ArcGIS Desktop Standard: Yes
  • ArcGIS Desktop Advanced: Yes

Related topics

  • An overview of the Layers and Table Views toolset
  • Using layers and table views
  • Working with layers and table views
  • Setting symbology using Apply Symbology From Layer tool

ArcGIS Desktop

  • Home
  • Documentation
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
Tell us what you think.
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal