Summary
Updates one or more network diagrams that are related to a given utility network or trace network.
Diagrams may need to be updated when they are either inconsistent or consistent. When a diagram is inconsistent, it means the network elements associated with some diagram features have been altered, and the diagram is out of date. A consistent diagram may need to be updated if the diagram template associated with it has been modified.
Caution:
If you have an open edit session, you must save your edits prior to running this tool. This ensures that the diagram reflects the latest changes made to the network topology in the database. If you fail to save your edits, the edits will not be reflected in the diagram.
Usage
This tool is not supported when working with a database connection to a utility network in an enterprise geodatabase. You must use either the related published utility network service or a utility network or trace network in a file geodatabase.
The input network or network diagram layer must be from either a utility network or trace network in a file geodatabase or utility network service.
This tool is not supported when working with a database connection to a utility network in an enterprise geodatabase. You must use either the related published utility network service or a utility network or trace network in a file geodatabase.
If both the Input Template Names and Input Diagram Names parameters are specified, the process will fail if the diagrams with the specified names are based on a different template name.
If the tool takes a network data element or layer as input, it requires either a list of diagram names to update or a specific diagram template (all the related diagrams are updated).
By default, this tool only processes inconsistent diagrams. To reflect changes that may have impacted the template rule and layout definitions, and therefore all the related diagrams (whether consistent or inconsistent), run this tool with the Update inconsistent diagrams only parameter unchecked.
To force the reexecution of automatic layouts at the end of the diagram update, you must check the Re-apply automatic layouts on the updated diagrams parameter.
Attempting to update subnetwork system diagrams will fail; these diagrams are exclusively maintained by the Update Subnetwork tool.
The Update Diagram tool fails in the following situations:
- There are dirty areas on network features initially used to generate the diagram, whether they are visible or aggregated.
- There are dirty areas on container network features related to network objects initially used to generate the diagram, whether they are visible or aggregated.
- There are dirty areas on new network features processed during the update.
- There are dirty areas on container network features related to new network objects processed during the update.
Syntax
UpdateDiagram(in_diagrams, {template_names}, {diagram_names}, {update_option}, {autolayout_option})
Parameter | Explanation | Data Type |
in_diagrams | The input network diagram layer to update or the utility network or trace network on which the set of specified input diagram names are based to update. | Utility Network Layer; Trace Network Layer; Utility Network; Trace Network; Diagram Layer |
template_names [templatenames,...] (Optional) | The names of the templates for which the related diagrams are to be processed. | String |
diagram_names [diagram_names,...] (Optional) | The names of the diagrams to be processed. | String |
update_option (Optional) | Specifies whether to update only diagrams that are inconsistent (the default) or all diagrams regardless of their consistency state.
| Boolean |
autolayout_option (Optional) | Specifies whether automatic layouts that are configured on the template on which the diagrams are based will be reapplied during the update process. By default, when automatic layouts are specified on a template, they are not reapplied during the update process.
| Boolean |
Derived Output
Name | Explanation | Data Type |
out_diagrams | The updated network diagram, utility network or trace network. | Utility Network Layer; Trace Network Layer; Utility Network; Trace Network; Diagram Layer |
Code sample
Update all inconsistent diagrams based on a given template using the UpdateDiagram tool.
import arcpy
input_Network = "https://cezembre.esri.com/server/rest/services/Naperville2_Electric_SQL/FeatureServer/0"
input_TemplateName = "Basic"
arcpy.UpdateDiagram_nd(input_Network, input_TemplateName)
Environments
Licensing information
- Basic: No
- Standard: Yes
- Advanced: Yes