RebarConstraintCreateConstraintToRebarEdge Method

This method creates a constraint of 'ToOtherRebar' type with Edge target type for a given RebarConstrainedHandle.

The RebarConstrainedHandle should belong to a Free Form Rebar, otherwise it will throw exception.


Namespace: Autodesk.Revit.DB.Structure
Assembly: RevitAPI (in RevitAPI.dll) Version: 27.0.4.0 (27.0.4.0)
Syntax
public static RebarConstraint CreateConstraintToRebarEdge(
	RebarConstrainedHandle handle,
	IList<ConstraintToRebarEdgeProperties> allEdgesProperties
)

Parameters

handle  RebarConstrainedHandle
The handle of the rebar that will be constrained.
allEdgesProperties  IListConstraintToRebarEdgeProperties
An array containing all target edges to which will be constrained and the constraint properties for each target edge.

Return Value

RebarConstraint
Returns the newly created RebarConstraint.
Exceptions
ExceptionCondition
ArgumentException handle is no longer valid. -or- Constrained rebar isn't a Free Form Rebar element. -or- The RebarConstrainedHandle doesn't allow constraint of RebarConstraintType.ToOtherRebar type, where target is TargetRebarConstraintType.Edge"/>. -or- All targets(TargetRebarEdge) should be different.
ArgumentNullException A non-optional argument was null
See Also