CreateReferenceElevationMarker Method


Creates a new ElevationMarker.

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

Syntax

C#
public static ElevationMarker CreateReferenceElevationMarker(
	Document document,
	ElementId viewFamilyTypeId,
	XYZ origin,
	ElementId viewPlanId
)
Visual Basic
Public Shared Function CreateReferenceElevationMarker ( _
	document As Document, _
	viewFamilyTypeId As ElementId, _
	origin As XYZ, _
	viewPlanId As ElementId _
) As ElevationMarker
Visual C++
public:
static ElevationMarker^ CreateReferenceElevationMarker(
	Document^ document, 
	ElementId^ viewFamilyTypeId, 
	XYZ^ origin, 
	ElementId^ viewPlanId
)

Parameters

document
Type: Autodesk.Revit.DBDocument
The document to which the new ElevationMarker will be added.
viewFamilyTypeId
Type: Autodesk.Revit.DBElementId
This ViewFamilyType will be used by all elevations hosted on the new ElevationMarker.
origin
Type: Autodesk.Revit.DBXYZ
The desired origin for the ElevationMarker.
viewPlanId
Type: Autodesk.Revit.DBElementId
The ViewPlan in which the reference ElevationMarker will appear. Reference ElevationMarkers only appear in one view.

Return Value

The new ElevationMarker.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException The ElementId viewPlanId does not correspond to a ViewPlan. -or- This view family type is not appropriate for ElevationMarkers. -or- Elevation view creation is not allowed in this family.
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null

See Also