ComputeSubcomponents Method


Splits a roof or floor element composed of planar surfaces into a set of roughly vertical extruded loops of uniform depth if possible.

Namespace: Autodesk.Revit.DB.IFC
Assembly: RevitAPIIFC (in RevitAPIIFC.dll) Version: 24.0.0.0 (24.0.0.0)
Since:  2016

Syntax

C#
public static IList<HostObjectSubcomponentInfo> ComputeSubcomponents(
	HostObject roofOrFloor
)
Visual Basic
Public Shared Function ComputeSubcomponents ( _
	roofOrFloor As HostObject _
) As IList(Of HostObjectSubcomponentInfo)
Visual C++
public:
static IList<HostObjectSubcomponentInfo^>^ ComputeSubcomponents(
	HostObject^ roofOrFloor
)

Parameters

roofOrFloor
Type: Autodesk.Revit.DBHostObject
The roof or floor.

Return Value

A collection of computed components.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException The host object roofOrFloor must be a floor or a non face-based roof.
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsInvalidOperationException The roof or floor cannot be split into subcomponents by this routine. Possible reasons are, among others: (1) the roof or floor contains non-planar surfaces, (2) the roof or floor cannot be divided into sub-components of equal thickness, or (3) the roof subcomponents contain inner boundary loops.

See Also

ArchiLabs

Stop fighting Revit automation.

Build repeatable BIM design and documentation workflows with scripts, data, and AI in one place, without wrestling brittle one-off automations.

Try ArchiLabs →