Helper method to get the total length of a poly ruler.
public static AnnLength GetPolyRulerLength(RasterCollection<AnnPoint> points,AnnUnit measurementUnit,AnnUnitConverter converter)
Public Shared Function GetPolyRulerLength( _ByVal points As Leadtools.RasterCollection(Of AnnPoint), _ByVal measurementUnit As Leadtools.Annotations.AnnUnit, _ByVal converter As Leadtools.Annotations.AnnUnitConverter _) As Leadtools.Annotations.AnnLength
public:static Leadtools.Annotations.AnnLength GetPolyRulerLength(Leadtools.RasterCollection<AnnPoint>^ points,Leadtools.Annotations.AnnUnit measurementUnit,Leadtools.Annotations.AnnUnitConverter^ converter)
points
Poly ruler points.
measurementUnit
The desired measurement unit.
converter
Unit converter to use.
An AnnLength object that contains the total length of the poly ruler in the desired measurement units.
GetPolyRulerLength is a helper method that can be used to obtain the total length of a poly ruler object.
using Leadtools;using Leadtools.Annotations;using Leadtools.Codecs;using Leadtools.WinForms;private void GetPolyRulerLengthExample(AnnContainer container, AnnPolyRulerObject polyRuler){// Get the total length in inchesAnnLength totalLength = AnnPolyRulerObject.GetPolyRulerLength(polyRuler.Points,AnnUnit.Inch,container.UnitConverter);MessageBox.Show("Total length is " + totalLength.ToString());}
Imports LeadtoolsImports Leadtools.AnnotationsImports Leadtools.CodecsImports Leadtools.WinFormsPrivate Sub GetPolyRulerLengthExample(ByVal container As AnnContainer, ByVal polyRuler As AnnPolyRulerObject)' Get the total length in inchesDim totalLength As AnnLength = AnnPolyRulerObject.GetPolyRulerLength(polyRuler.Points,AnnUnit.Inch,container.UnitConverter)MessageBox.Show("Total length is " + totalLength.ToString())End Sub
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
