Convert Method


Converts the set of MEP design elements into fabrication parts.

Namespace: Autodesk.Revit.DB.Fabrication
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since:  2017

Syntax

C#
public DesignToFabricationConverterResult Convert(
	ISet<ElementId> selection,
	int serviceId
)
Visual Basic
Public Function Convert ( _
	selection As ISet(Of ElementId), _
	serviceId As Integer _
) As DesignToFabricationConverterResult
Visual C++
public:
DesignToFabricationConverterResult Convert(
	ISet<ElementId^>^ selection, 
	int serviceId
)

Parameters

selection
Type: System.Collections.GenericISetElementId
The set of element identifiers to convert from MEP design elements to fabrication parts.
serviceId
Type: SystemInt32
The identifier of the fabrication service.

Remarks

After this method has been invoked, call:

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException the selection contains invalid elements to convert. -or- the specified fabrication service is not valid for all domains in the selection.
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsInvalidOperationException no fabrication configuration is loaded.

See Also

ArchiLabs Desktop

Put AI to work inside Revit.

Give Desktop your instructions and project files to build Revit families, update model elements, and create views and schedules. Works directly in Revit and AutoCAD.

Explore Desktop →