GetCategory Method (Document, BuiltInCategory)
Retrieves a category object corresponding to a BuiltInCategory id.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 20.0.0.0 (20.1.1.1)
Since:  2016

Syntax

C#
public static Category GetCategory(
	Document document,
	BuiltInCategory categoryId
)
Visual Basic
Public Shared Function GetCategory ( _
	document As Document, _
	categoryId As BuiltInCategory _
) As Category
Visual C++
public:
static Category^ GetCategory(
	Document^ document, 
	BuiltInCategory categoryId
)

Parameters

document
Type: Autodesk.Revit.DB..::..Document
The document.
categoryId
Type: Autodesk.Revit.DB..::..BuiltInCategory
A build in category id.

Return Value

Returns a category object corresponding to a BuiltInCategory id.

See Also