Alter Diagram Properties (Network Diagram)

Summary

Alters properties for a stored network diagram.

Caution:

If the diagram is related to a utility network or trace network in an enterprise geodatabase, only the diagram owner and the portal utility network owner or the portal trace network owner can use the Alter Diagram Properties tool to change the access right level of the input diagram.

Usage

  • This tool is not supported when working with a database connection to a utility network or trace network in an enterprise geodatabase. You must use either the related published utility network or trace network service, or a utility network or trace network in a file geodatabase.

  • The input network diagram layer must be from either a utility network or a trace network in a file geodatabase or a network diagram service.

  • The tool alters diagram properties that have been initialized on your stored diagrams. With this tool, you can do the following:

    • Rename the diagram.
    • Modify its access right level.
    • Edit the diagram tags.

Parameters

LabelExplanationData Type
Input Network Diagram Layer

The stored network diagram to alter.

Diagram Layer
Network Diagram Name

The new name for the input network diagram.

String
Network Diagram Access Rights
(Optional)

Specifies the access right level of the input diagram.

  • Public —Other users will have full access to the diagram; everyone can see, edit, update, and overwrite the diagram. However, no one except the diagram owner and the portal utility network owner—in the case of diagrams related to a utility network in an enterprise geodatabase—can use the Alter Diagram Properties tool to change the access right level. This is the default.
  • Protected —Other users will have read-only access to the diagram. They cannot edit, update, or overwrite the diagram.
  • Private — Other users will not have access to the diagram. The corresponding diagram item will be hidden from other users in the Find Diagrams pane.
String
Tags (optional)
(Optional)

One or several tags that will help find the stored diagram. These tags can be used in the Find Diagrams pane.

To add several tags, use the number sign (#) to separate each tag. This also allows a more thorough and efficient diagram search.

String

Derived Output

LabelExplanationData Type
Altered Network Diagram Layer

The updated network diagram.

Diagram Layer

arcpy.nd.AlterDiagramProperties(in_network_diagram_layer, out_name, {access_right_type}, {tags})
NameExplanationData Type
in_network_diagram_layer

The stored network diagram to alter.

Diagram Layer
out_name

The new name for the input network diagram.

String
access_right_type
(Optional)

Specifies the access right level of the input diagram.

  • PUBLICOther users will have full access to the diagram; everyone can see, edit, update, and overwrite the diagram. However, no one except the diagram owner and the portal utility network owner—in the case of diagrams related to a utility network in an enterprise geodatabase—can use the Alter Diagram Properties tool to change the access right level. This is the default.
  • PROTECTEDOther users will have read-only access to the diagram. They cannot edit, update, or overwrite the diagram.
  • PRIVATE Other users will not have access to the diagram. The corresponding diagram item will be hidden from other users in the Find Diagrams pane.
String
tags
(Optional)

One or several tags that will help find the stored diagram. These tags can be used in the Find Diagrams pane.

To add several tags, use the number sign (#) to separate each tag. This also allows a more thorough and efficient diagram search.

String

Derived Output

NameExplanationData Type
out_network_diagram_layer

The updated network diagram.

Diagram Layer

Code sample

AlterDiagramProperties example (stand-alone script)

The following stand-alone script uses the AlterDiagramProperties tool to retrieve a stored network diagram in the database and change its properties.

# Name: AlterDiagramProperties.py
# Description:  Retrieve a stored diagram and change its properties.

# Import system modules
import arcpy

# Initialize variables
input_network = "https://cezembre.esri.com/server/rest/services/Naperville_ORA/FeatureServer/8"
input_DiagramName = "Test"

# Set overwrite option
arcpy.env.overwriteOutput = True

# Retrieving a given stored diagram and transforming it as a diagram layer 
arcpy.MakeDiagramLayer_nd(input_network, input_DiagramName, "built_diagramlayer")

# Renaming this diagram to "SmartTree1_Test", changing its access right 
# level, and specifying tags 
arcpy.AlterDiagramProperties_nd("built_diagramlayer", "SmartTree1_Test", 
                                "PROTECTED", 
                                "Distribution#RMT0003#Naperville North East")

Environments

This tool does not use any geoprocessing environments.

Licensing information

  • Basic: No
  • Standard: Yes
  • Advanced: Yes

Related topics