Returns the distance from this point to the specified point.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 21.0.0.0 (21.1.1.109)
Syntax
C# |
---|
public double DistanceTo( XYZ source ) |
Visual Basic |
---|
Public Function DistanceTo ( _ source As XYZ _ ) As Double |
Visual C++ |
---|
public: double DistanceTo( XYZ^ source ) |
Parameters
- source
- Type: Autodesk.Revit.DB..::..XYZ
The specified point.
Return Value
The real number equal to the distance between the two points.
Remarks
The distance between the two points is equal to the length of the vector
that joins the two points.
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions..::..ArgumentNullException | Thrown when source is nullNothingnullptra null reference (Nothing in Visual Basic). |