Create Method


Creates a new instance of a panel schedule template.

Namespace: Autodesk.Revit.DB.Electrical
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)

Syntax

C#
public static PanelScheduleTemplate Create(
	Document document,
	PanelScheduleType type,
	PanelConfiguration config,
	string strName
)
Visual Basic
Public Shared Function Create ( _
	document As Document, _
	type As PanelScheduleType, _
	config As PanelConfiguration, _
	strName As String _
) As PanelScheduleTemplate
Visual C++
public:
static PanelScheduleTemplate^ Create(
	Document^ document, 
	PanelScheduleType type, 
	PanelConfiguration config, 
	String^ strName
)

Parameters

document
Type: Autodesk.Revit.DBDocument
The document where the element will be created and added.
type
Type: Autodesk.Revit.DB.ElectricalPanelScheduleType
The panel schedule type.
config
Type: Autodesk.Revit.DB.ElectricalPanelConfiguration
The panel configuration type.
strName
Type: SystemString
The name of the panel schedule template to be created.

Return Value

The newly created panel schedule template element.

Remarks

If the given name has already been used by existing panel schedule templates, a unique name will be used for the newly created template.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException The type is not valid for this element. -or- The config is not valid for panel schedule type type of this template.
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration

See Also