Create Method (Document, Element, IList(CurveLoop), XYZ, XYZ)


Creates a FabricArea from an array of curves.

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

Syntax

C#
[ObsoleteAttribute("This method is obsolete in Revit 2015. Use the Create() method that accepts additional arguments (the id of the FabricAreaType, and FabricSheetType).")]
public static FabricArea Create(
	Document aDoc,
	Element hostElement,
	IList<CurveLoop> curveLoops,
	XYZ majorDirection,
	XYZ majorDirectionOrigin
)
Visual Basic
<ObsoleteAttribute("This method is obsolete in Revit 2015. Use the Create() method that accepts additional arguments (the id of the FabricAreaType, and FabricSheetType).")> _
Public Shared Function Create ( _
	aDoc As Document, _
	hostElement As Element, _
	curveLoops As IList(Of CurveLoop), _
	majorDirection As XYZ, _
	majorDirectionOrigin As XYZ _
) As FabricArea
Visual C++
[ObsoleteAttribute(L"This method is obsolete in Revit 2015. Use the Create() method that accepts additional arguments (the id of the FabricAreaType, and FabricSheetType).")]
public:
static FabricArea^ Create(
	Document^ aDoc, 
	Element^ hostElement, 
	IList<CurveLoop^>^ curveLoops, 
	XYZ^ majorDirection, 
	XYZ^ majorDirectionOrigin
)

Parameters

aDoc
Type: Autodesk.Revit.DB Document
The document.
hostElement
Type: Autodesk.Revit.DB Element
The element that will host the FabricArea. The host can be either a Structural Floor or Structural Wall.
curveLoops
Type: System.Collections.Generic IList CurveLoop
An array of curves that will define the outline of the FabricArea. This includes curves defining openings in the interior of the area.
majorDirection
Type: Autodesk.Revit.DB XYZ
A vector to define the major direction of the FabricArea.
majorDirectionOrigin
Type: Autodesk.Revit.DB XYZ
An origin point of the major direction line

Return Value

The newly created FabricArea.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException Not all curveLoops in curveLoops are closed and continuous. -or- Not all curveLoops in curveLoops are in the same plane. -or- curveLoops should only contain lines or arcs. -or- The document aDoc does not contain the element hostElement -or- the host Element is not a valid host for Area Reinforcement, Path Reinforcement, Fabric Area or Fabric Sheet.
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was NULL
Autodesk.Revit.Exceptions ArgumentOutOfRangeException majorDirection has zero length.
Autodesk.Revit.Exceptions DisabledDisciplineException None of the following disciplines is enabled: Structural.

See Also