Create Method (Document, String, ElementId, LoadCaseCategory)


Load Case Create(Document, String, Element Id, Load Case Category) Method

Creates a new LoadCase.

Namespace: Autodesk.Revit.DB.Structure
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.3.0.0 (25.3.0.0)
Syntax
public static LoadCase Create(
	Document document,
	string name,
	ElementId natureId,
	LoadCaseCategory loadCaseCategory
)

Parameters

document Document
The Document to which new load case element will be added.
name String
The name of the load case.
natureId ElementId
The load nature ID.
loadCaseCategory LoadCaseCategory
The predefined load case category.

Return Value

LoadCase
The newly created load case element if successful, otherwise.
Exceptions
Exception Condition
ArgumentException The given name is not unique.
ArgumentNullException A non-optional argument was null
ArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration
Remarks
This method is designed to create LoadCase that is associated with one of the predefined category.
See Also