VB.NET Leitcode Generator Size Setting Tutorial

sample source code to generate linear Leitcode images and adjust barcode size in VB.NET


  • Easy to be installed in VB.NET IDEs
  • Reusable .NET component
  • Easy to define the width and height of a module bar in Leitcode
  • Supported unit of measure include Pixel, Cm, and Inch
  • Print flexible margins around Leitcode Symbol
  • Support symbol and background color setting
  • Generate Leitcode in GIF, TIFF, BMP, PNG, and JPEG

Leticode, also known as German Postal 2 of 5 Leitcode, Deutsche Post Leitcode Barcode, is a postal barcode used by the Deutsche Post AG (DHL).

 

Leitcode Symbology Structure



W: the width of Leitcode, controlled by property BarCodeWidth

X (X ≥ 1 pixel): the width of a module bar, controlled by property X

Q (Q ≥ 10X): the width of the quiet zone, related to property LeftMargin & RightMargin


More information about Leitcode barcode settings in Excel Barcode Generator,please see:

 

Leitcode VB.NET Generator Size Setting Tutorial

After Leitcode VB.NET Generator installation, get it ready in VB.NET by placing the following statement:

Dim leitcode As OnBarcode.Barcode.Linear

leitcode = New OnBarcode.Barcode.Linear

leitcode.Type = OnBarcode.Barcode.BarcodeType.LEITCODE

UOM

UOM is the controller of size setting unit. Pixel, Cm, and Inch are provided as its options. The default value of UOM is Pixel. For example, type the following statement to select Pixel as the unit of size setting measure:

leitcode.UOM = OnBarcode.Barcode.UnitOfMeasure.PIXEL

X & Y

Property X (Type: Float; Default: 1) and Property Y (Type: Float; Default: 60) are used in Leitcode barcode symbol size setting. X is for the module width setting, and Y controls the height of the bar.

Sample usage:

leitcode.X = 2

leitcode.Y = 70

BarCodeHeight & BarCodeWidth

Property BarCodeHeight (Type: Float; Default: 0) and Property BarCodeWidth (Type: Float; Default: 0) to set the size of the whole image.

Sample usage:

leitcode.BarcodeHeight = 60

leitcode.BarcodeWidth = 175

AutoResize

When the value of X, Y, BarCodeWidth, and BarCodeHeight conflict with each other, Property AutoResize (Type: bool; Default: False) should be enabled to solve the problem and make the Leitcode 100% compatible with its symbology specification. See Leitcode Barcode Size in VB.NET to know more usage of AutoResize.

Sample usage:

leitcode.X = 2

leitcode.BarcodeHeight = 60

leitcode.AutoResize = True

TopMargin, BottomMargin, LeftMargin, & RightMargin

Using Leitcode VB.NET Generator, a quiet zone with 10X width will be generated automatically at each side of the Leitcode. When wider quiet zone is needed, you can increase the value of properties LeftMargin (Type: Float; Default: 0) and RightMargin (Type: Float; Default: 0). You can also create margins using TopMargin (Type: Float; Default: 0) and BottomMargin (Type: Float; Default: 0).

Sample usage:

leitcode.TopMargin = 10

leitcode.BottomMargin = 10

leitcode.LeftMargin = 10

leitcode.RightMargin = 10

TextMargin

Human readable text are required in almost every linear barcode symbology. Property TextMargin (Type: Float; Default: 6 pixel) is used to set the space between Leitcode bar code and the human readable text below the barcode.

Sample usage:

leitcode.TextMargin = 10







OnBarcode is a market-leading provider of barcode generator, reader controls and components for ASP.NET, Windows Forms, WPF, as well Java, Android, iOS (iPhone, iPad) across all major enterprise development platforms. We provides high quality tutorials and guides for various linear, 2d barcode information, such as C# Barcode, QR Code C#, QR Code VB.NET, QR Code ASP.NET, QR Code .NET, ASP.NET Barcode. OnBarcode barcode products are supported by RasterEdge ASP.NET Document Viewer, which supports ASP.NET PDF Viewer, ASP.NET MVC Document Viewer, ASP.NET PDF Editor, MVC PDF Viewer. And provide high quality C# Convert PDF to Tiff, C# Convert PDF to Word, C# Convert PDF to HTML, C# Convert PDF to Jpeg images, and their easy and simple documents, like C# PDF SDK, C# extract text from PDF, C# Compress PDF, Print PDF in C# and C# extract image from PDF.
Terms of Use | Privacy Policy
Copyright © OnBarcode.com . All rights reserved.