Products | Support | Email a link to this topic. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 19.0.5.2
|
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 )
GetPolyRulerLength is a helper method that can be used to obtain the total length of a poly ruler object.
Imports Leadtools Imports Leadtools.Annotations Imports Leadtools.Codecs Imports Leadtools.WinForms 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
using Leadtools; using Leadtools.Annotations; using Leadtools.Codecs; using Leadtools.WinForms; 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()); }