Leadtools.Annotations Namespace > AnnPolyRulerObject Class : GetPolyRulerLength Method |
public static AnnLength GetPolyRulerLength( RasterCollection<AnnPoint> points, AnnUnit measurementUnit, AnnUnitConverter converter )
'Declaration Public Shared Function GetPolyRulerLength( _ ByVal points As RasterCollection(Of AnnPoint), _ ByVal measurementUnit As AnnUnit, _ ByVal converter As AnnUnitConverter _ ) As AnnLength
'Usage Dim points As RasterCollection(Of AnnPoint) Dim measurementUnit As AnnUnit Dim converter As AnnUnitConverter Dim value As AnnLength value = AnnPolyRulerObject.GetPolyRulerLength(points, measurementUnit, converter)
public static AnnLength GetPolyRulerLength( RasterCollection<AnnPoint> points, AnnUnit measurementUnit, AnnUnitConverter converter )
function Leadtools.Annotations.AnnPolyRulerObject.GetPolyRulerLength( points , measurementUnit , converter )
public: static AnnLength GetPolyRulerLength( RasterCollection<AnnPoint>^ points, AnnUnit measurementUnit, AnnUnitConverter^ converter )
GetPolyRulerLength is a helper method that can be used to obtain the total length of a poly ruler object.
Private Sub GetPolyRulerLengthExample(ByVal container As AnnContainer, ByVal polyRuler As AnnPolyRulerObject) ' Get the total length in inches Dim totalLength As AnnLength = AnnPolyRulerObject.GetPolyRulerLength( _ polyRuler.Points, _ AnnUnit.Inch, _ container.UnitConverter) MessageBox.Show("Total length is " + totalLength.ToString()) End Sub
private void GetPolyRulerLengthExample(AnnContainer container, AnnPolyRulerObject polyRuler) { // Get the total length in inches AnnLength totalLength = AnnPolyRulerObject.GetPolyRulerLength( polyRuler.Points, AnnUnit.Inch, container.UnitConverter); MessageBox.Show("Total length is " + totalLength.ToString()); }
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2