NewLoadUsage Method


Creates a new instance of a LoadUsage element within the project.

Namespace: Autodesk.Revit.Creation
Assembly: RevitAPI (in RevitAPI.dll) Version: 16.0.0.0 (16.0.0.0)

Syntax

C#
[ObsoleteAttribute("This method is obsolete in Revit 2016. Use LoadUsage.Create() instead.")]
public LoadUsage NewLoadUsage(
	string name
)
Visual Basic
<ObsoleteAttribute("This method is obsolete in Revit 2016. Use LoadUsage.Create() instead.")> _
Public Function NewLoadUsage ( _
	name As String _
) As LoadUsage
Visual C++
[ObsoleteAttribute(L"This method is obsolete in Revit 2016. Use LoadUsage.Create() instead.")]
public:
LoadUsage^ NewLoadUsage(
	String^ name
)

Parameters

name
Type: System String
The not empty name for the Load Usage Element to create.

Return Value

If successful and there isn't the Load Usage Element with the same name NewLoadUsage returns an object for the newly created LoadUsage. If such element exist it returns existing element. a null reference ( Nothing in Visual Basic) is returned if the operation fails.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions InvalidOperationException If the product is not Revit Structure.

See Also