KA.Barcode for .NET Suite
Guide for Resizing PLANET Barcodes in VB.NET
Complete VB.NET source code to generate, print PLANET images and change barcode size with .NET Control

  • Generate and draw high print-quality PLANET barcodes in .NET projects with VB.NET PLANET Generator

  • Easy to customize PLANET barcode width and height, vertical and horizontal margins

  • Enable to set and adjust the bar module width and height of PLANET in VB.NET

  • Support adjustment of the space between PLANET image bars and human-readable text

  • Set and control the short bar to tall bar ratio of PLANET image

  • Simple to draw and print PLANET with minimum bar module (X)

  • Capable of drawing a fixed PLANET image width with maximum bar module

  • Use pixel, cm, and inch as the unit of measure for PLANET barcode generation in VB.NET

  • Created PLANET barcodes comply with its latest barcode specification

PlANET, is also named as USPS PLANET Barcode, USPS Confirms Service Barcode. More details about PLANET in KA.Barcode Generator for VB.NET: PLANET Image in VB.NET and PLANET Encoded Data in VB.NET.


PLANET Generator in VB.NET Related Software

PLANET Barcode Library for C#.NET

PLANET Barcode Library for Windows Forms

PLANET Barcode Library for ASP.NET Web Forms

PLANET Barcode Add-In for Microsoft Excel


PLANET Size Setting in VB.NET Generator Overview

PLANET Image Width Setting

The following chart explains the essential parameters of PLANET barcode image setting in our VB.NET PLANET Generator SDK.

Parameter Parameter Description Range Related Property
Image Width(W) The width of the PLANET image W ≥ 143 pixel BarCodeWidth
Module Bar Width (X) The width of the module bar in PLANET X ≥ 1 pixel X
Left Quiet Zone Width (Q1) The space between the left edge of the image and the leftmost bar; Q1= 10 X + Left Margin Width Q1 ≥ 10X LeftMargin
Right Quiet Zone Width (Q2) The space between the right edge of the image and the rightmost bar; Q2= 10 X + Right Margin Width Q2 ≥ 10X RightMargin

Attention: the number of data characters also has an influence on the barcode width. For more details, please refer to Setting PLANET Image in Visual Basic .NET Generator.

PLANET Image Height Setting

The height of PLANET barcode image is determined by several factors, including top and bottom margin width, bar height, text height, and the space between image bar and text.

Parameter Parameter Description Range Related Property
Image Height (H) The height of PLANET image H ≥ 70 pixel H
Bar Height (Y) The height of PLANET tall bar Y ≥ 50 pixel Y
Short Bar Height (SY) The height of PLANET short bar 0 < S < 1 ShortTallRatio
Top Margin Width The height of PLANET top margin ≥ 0 TopMargin
Bottom Margin Width The height of PLANET bottom marginn ≥ 0 BottomMargin
Text Height The font style of PLANET image human-readable text - Text Font
Text Margin The space between PLANET image bar and text ≥ 0 TextMargin


Using VB.NET Generator to Set PLANET Barcode Size

In this section, we will give detail explanation for how to set and change POSTNET barcode image size in .NET applications with Visual Basic.

KeepAutomation VB.NET PLANET Generator Library offers developers with a full set of properties for PLANET size setting. Please fistly install our VB.NET PLANET Barcode Generator. Then do as follows:

Add the namespace reference code to your VB.NET projects.

Dim Planet As KeepAutomation.Barcode.Bean.BarCode

Planet = New KeepAutomation.Barcode.Bean.BarCode()

Type the following Visual Basic code to refer to PLANET barcode in VB.NET PLANET Generation Library.

Planet.Symbology = KeepAutomation.Barcode.Symbology.Planet

Input the following VB code and type a string value for CodeToEncode, which will be encoded as data in your PLANET. And you can get more information about data encoding from PLANET data encoding in VB.NET.

Planet.CodeToEncode = "11223344556"

BarcodeUnit

Property BarcodeUnit stands for the unit of measure for PLANET generation in VB.NET. Before setting the bar width and image size, you should choose from the provided unit of measure, including Pixel, Cm, and Inch. In our software, BarcodeUnit is default by Pixel.

Planet.BarcodeUnit = KeepAutomation.Barcode.BarcodeUnit.Pixel

X

Property X (Float; Default: 1) is designed to set PLANET bar module width in VB.NET class. And this parameter is user defined.

Planet.X = 2

Y

Property Y (Float; Default: 50) is applied to set the bar height of PLANET barcode in Visual Basic .NET class. In our PLANET barcode generation control for VB.NET, this property is customizable.

Planet.Y = 55

ShortTallRatio

Property ShortTallRatio (Float; Default: 0.4 pixel) is used to adjust PLANET short to tall bar ratio. And its value should ranges from 0 to 1.

Planet.ShortTallRatio = 0.5

BarCodeHeight and BarCodeWidth

VB.NET PLANET Generator Library also has functional properties, BarCodeHeight (Float; Default: 0) and BarCodeWidth (Float; Default: 0), which are used to control the whole PLANET barcode image width and height.

Planet.BarCodeWidth = 160

Planet.BarCodeHeight = 68

Note: If your settings of these two parameters conflict with your target bar width or bar height, you can simply enable AutoResize property. In this way, our software will automatically adjust your PLANET barcode, complying with PLANET barcode specification.

TopMargin, BottomMargin, LeftMargin, and RightMargin

In general, our VB.NET PLANET Generator will add quiet zones (minimum value: 10X) on the left and right of the image. Certainly, you can control the whole image width by setting LeftMargin (Float; Default: 0) and RightMargin (Float; Default: 0). Also, the whole image height of PLANET can be enlarged by adjusting TopMargin (Float; Default: 0) and BottomMargin (Float; Default: 0).

Planet.TopMargin = 4

Planet.BottomMargin = 4

Planet.LeftMargin = 2

Planet.RightMargin = 2

TextMargin

The property, TextMargin (Float; Default: 6 pixel) determines the space between PLANET image bar and the human readable text.

Planet.TextMargin = 8