Share

Material.IsMaterialOrValidDefault Method

Validates whether the specified element id is a material element.


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

Syntax

C#

public static bool IsMaterialOrValidDefault(
	Element pElem,
	ElementId materialId
)

Parameters

pElem  Element
An element which will be applied the material
materialId  ElementId
The element id to be checked.

Return Value

Boolean
True if the element a material element or invalidElementId, which means take material from category, false otherwise.

Exceptions

ExceptionCondition
ArgumentNullException A non-optional argument was null

See Also

Reference

Was this information helpful?