C#
VB
WinRT C#
C++
Defines an interface with properties and methods for representing Bates stamp elements.
public interface IAnnBatesElement Public Interface IAnnBatesElement public interface IAnnBatesElement function Leadtools.Annotations.Documents.IAnnBatesElement() public:interface class IAnnBatesElement abstract
This example creates different Bates stamp elements and sets their properties.
using Leadtools.Annotations.Core;using Leadtools.Annotations.Documents;using LeadtoolsExamples.Common;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()); // the output will be "9/14/15"//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.CoreImports Leadtools.Annotations.DocumentsImports 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()) ' the output will be "9/14/15"'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
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
