SetVisibility Method


Sets if elements of the given category will be visible in this view.

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

Syntax

C#
public void SetVisibility(
	Category category,
	bool visible
)
Visual Basic
Public Sub SetVisibility ( _
	category As Category, _
	visible As Boolean _
)
Visual C++
public:
void SetVisibility(
	Category^ category, 
	bool visible
)

Parameters

category
Type: Autodesk.Revit.DB Category
The category.
visible
Type: System Boolean
True to make elements of this category visible, false to make them invisible.

Remarks

This affects only if the category is set visible or invisible individually. Other Revit mechanisms may also affect the visibility of elements of this category, including:
  • the category classes settings for model categories, annotation categories, import categories or analytical model categories.
  • view filters
Thus setting this value may not affect the actual visibility of elements of this category in the view.

See Also