public interface IAnnBatesElement Public Interface IAnnBatesElement public:interface class IAnnBatesElement abstract
This example creates different Bates stamp elements and sets their properties.
using Leadtools.Annotations.BatesStamp;public void IAnnBateElement_IAnnBateElement(){//The base interface for all bates stamp elementsIAnnBatesElement baseElement = null;//Create AnnBatesDateTime element and set its propertiesAnnBatesDateTime dateTimeElement = new AnnBatesDateTime();dateTimeElement.CurrentDateTime = DateTime.Now;dateTimeElement.Kind = AnnDateTimeKind.Local;dateTimeElement.Format = "M/d/yy";baseElement = dateTimeElement;//print the content of this dateTimeElementDebug.WriteLine(baseElement.AsString());//Create AnnBatesNumber element and set its propertiesAnnBatesNumber numberElement = new AnnBatesNumber();numberElement.NumberOfDigits = 4;numberElement.PrefixText = "PrefixTest";numberElement.StartNumber = 5;numberElement.SuffixText = "SuffixTest";numberElement.UseAllDigits = true;numberElement.AutoIncrement = true;baseElement = numberElement;//print the content of this numberElementDebug.WriteLine(baseElement.AsString()); // the output will be "PrefixTest0005SuffixTest"//Create AnnBatesText elementAnnBatesText textElement = AnnBatesText.Create("This is text");baseElement = textElement;//print the content of this textElementDebug.WriteLine(baseElement.AsString()); // the output will be "This is text"}
Imports Leadtools.Annotations.EngineImports Leadtools.Annotations.BatesStampImports LeadtoolsExamples.CommonPublic Sub IAnnBateElement_IAnnBateElement()'The base interface for all Bates stamp elementsDim baseElement As IAnnBatesElement = Nothing'Create AnnBatesDateTime element and set its propertiesDim dateTimeElement As AnnBatesDateTime = New AnnBatesDateTime()dateTimeElement.CurrentDateTime = DateTime.NowdateTimeElement.Kind = AnnDateTimeKind.LocaldateTimeElement.Format = "M/d/yy"baseElement = dateTimeElement'print the content of this dateTimeElementDebug.WriteLine(baseElement.AsString())'Create AnnBatesNumber element and set its propertiesDim numberElement As AnnBatesNumber = New AnnBatesNumber()numberElement.NumberOfDigits = 4numberElement.PrefixText = "PrefixTest"numberElement.StartNumber = 5numberElement.SuffixText = "SuffixTest"numberElement.UseAllDigits = TruenumberElement.AutoIncrement = TruebaseElement = numberElement'print the content of this numberElementDebug.WriteLine(baseElement.AsString()) ' the output will be "PrefixTest0005SuffixTest"'Create AnnBatesText elementDim textElement As AnnBatesText = AnnBatesText.Create("This is text")baseElement = textElement'print the content of this textElementDebug.WriteLine(baseElement.AsString()) ' the output will be "This is text"End Sub
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document
