TangentLength Example
Examples:
Sub Example_TangentLength_AlignCurve()
' This example returns the TangentLength for the first Curve found in the
' first Alignment in the collection.
Dim align As AeccAlignment
Dim alignEnts As AeccAlignEntity
Set align = AeccApplication.ActiveProject.Alignments.Item(0)
Dim alignMsg As String
alignMsg = "There is no Curve entity in the first Alignment."
' Find first Curve in the alignment
For Each alignEnt In align.AlignEntities
If alignEnt.Type = kCurve Then
alignMsg = "The TangentLength for the first Curve in the alignment is: " _
& Format(alignEnt.TangentLength, "0.00")
Exit For
End If
Next
MsgBox alignMsg, vbInformation, "TangentLength Example"
End Sub
Sub Example_TangentLength_ParcelCurve()
' This example returns the TangentLength for the first curve in the
' first Parcel in the collection.
Dim parcel As AeccParcel
Dim parcelEnt As AeccParcelEntity
Set parcel = AeccApplication.ActiveProject.Parcels.Item(0)
Set parcelEnt = parcel.ParcelEntities.Item(0)
Dim parcelMsg As String
parcelMsg = "There is no Curve entity in the first Parcel."
' Find first Curve in the parcel
For Each parcelEnt In parcel.ParcelEntities
If parcelEnt.Type = kParcelCurve Then
parcelMsg = "The TangentLength for the first Curve in the Parcel is: " _
& Format(parcelEnt.TangentLength, "0.00")
Exit For
End If
Next
MsgBox parcelMsg, vbInformation, "TangentLength Example"
End Sub