AreaReinforcementCreate(Document, Element, XYZ, ElementId, ElementId, ElementId) Method |
Creates a new AreaReinforcement object based on a host boundary.
Namespace: Autodesk.Revit.DB.StructureAssembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntaxpublic static AreaReinforcement Create(
Document document,
Element hostElement,
XYZ majorDirection,
ElementId areaReinforcementTypeId,
ElementId rebarBarTypeId,
ElementId rebarHookTypeId
)
Public Shared Function Create (
document As Document,
hostElement As Element,
majorDirection As XYZ,
areaReinforcementTypeId As ElementId,
rebarBarTypeId As ElementId,
rebarHookTypeId As ElementId
) As AreaReinforcement
public:
static AreaReinforcement^ Create(
Document^ document,
Element^ hostElement,
XYZ^ majorDirection,
ElementId^ areaReinforcementTypeId,
ElementId^ rebarBarTypeId,
ElementId^ rebarHookTypeId
)
static member Create :
document : Document *
hostElement : Element *
majorDirection : XYZ *
areaReinforcementTypeId : ElementId *
rebarBarTypeId : ElementId *
rebarHookTypeId : ElementId -> AreaReinforcement
Parameters
- document Document
-
The document.
- hostElement Element
-
The element that will host the AreaReinforcement. The host can be a Structural Floor, Structural Wall, Structural Slab, or a Part created from a structural layer belonging to one of those element types.
- majorDirection XYZ
-
A vector to define the major direction of the AreaReinforcement.
- areaReinforcementTypeId ElementId
-
The id of the AreaReinforcementType.
- rebarBarTypeId ElementId
-
The id of the RebarBarType.
- rebarHookTypeId ElementId
-
The id of the RebarHookType.
If this parameter is InvalidElementId, it means to create a rebar with no hooks.
Return Value
AreaReinforcement
The newly created AreaReinforcement.
ExceptionsException | Condition |
---|
ArgumentException |
The element hostElement was not found in the given document.
-or-
the host Element is not a valid host for Area Reinforcement, Path Reinforcement, Fabric Area or Fabric Sheet.
-or-
areaReinforcementTypeId should refer to an AreaReinforcementType element.
-or-
rebarBarTypeId should refer to an RebarBarType element.
-or-
rebarHookTypeId should be invalid or refer to an RebarHookType element.
|
ArgumentNullException |
A non-optional argument was null
|
ArgumentOutOfRangeException |
majorDirection has zero length.
|
ForbiddenForDynamicUpdateException |
This method may not be called during dynamic update.
|
See Also