ArcGIS Pro 2.6 API Reference Guide
CreateGroupTemplateDefinition Method

ArcGIS.Desktop.Mapping Namespace > MappingExtensions Class : CreateGroupTemplateDefinition Method
the layer to use as the base.
the template name for the new group template.
the name of the template used as the base.
Optional description of the template.
Optional. A set of tags.
Creates a new group template object using the specified definition. Adds the base template specified to the group template as the base part. This method must be called on the MCT. Use QueuedTask.Run. Use this method in conjunction with calls to AddComponentTemplate for each component part. Once the group template is fully defined, use CreateTemplate(Layer,CIMEditingTemplate) to add the template to the template manager.
Syntax
Public Shared Function CreateGroupTemplateDefinition( _
   ByVal layer As BasicFeatureLayer, _
   ByVal groupTemplateName As String, _
   ByVal baseTemplateName As String, _
   Optional ByVal description As String, _
   Optional ByVal tags() As String _
) As CIMGroupEditingTemplate

Parameters

layer
the layer to use as the base.
groupTemplateName
the template name for the new group template.
baseTemplateName
the name of the template used as the base.
description
Optional description of the template.
tags
Optional. A set of tags.

Return Value

the newly created group template object. Null if it cannot be created.
Exceptions
ExceptionDescription
The layer must exist and the base template name must exist on the layer. Group template name must not be empty and be unique.
This method must be called on the Main CIM Thread. Use QueuedTask.Run.
Remarks
Group templates are not supported for multipoint, multipatch, annotation or dimension layers.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 7

See Also

Reference

MappingExtensions Class
MappingExtensions Members