.NET UPC-A Barcode Generator
Generate UPC-A barcode labels using c#, vb.net in asp.net mvc, windows application


How to Generate Linear UPC-A Barcode in ASP.NET, .NET WinForms & .NET Reports



  • Compatible with GS1 Barcode Standard for linear UPC-A encoding in .NET applications
  • Generate and create linear UPC-A in .NET WinForms, ASP.NET and .NET Class
  • Dynamically stream 1D UPC-A barcode images in Microsoft Internet Information Services
  • Easy to print linear UPC-A in Visual Studio.NET, supporting drag & drop and C#/VB.NET coding
  • Easily add two or five digits supplement barcodes to UPC-A in .NET
  • Automatically add check digit for 1D UPC-A barcodes in .NET projects
  • Print and save linear UPC-A barcode image in gif, jpeg, png, tiff and bitmap images
  • Widely-used and advanced linear UPC-A barcode generating library SDK
UPC-A .NET Barcode Generator Overview
UPC-A .NET barcode generator is a tailored barcode SDK for UPC-A included in KA.Barcode for .NET Suite for developers to generate accurate linear UPC-A, UPC-A+2, UPC-A+5 in various .NET projects.

generate and print barcode in asp.net c#, c# barcode generator code project, c# barcode and qr code generator, native barcode generator for crystal reports free download, progress bar code in c# windows application, barcode reader from image c#
UPC-A Barcode Introduction
UPC-A is the standard version of Universal Product Code (UPC) barcodes that is widely used in North America, and in countries including the UK, Australia, and New Zealand for tracking trade items in stores.
UPC-A Barcode Encodable Data
  • 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
UPC-A Data Capacity
  • 12 numeric digits (Please input only 11 digits, for K.A.Barcode automatically add the last check digit for you)
UPC-A Barcode Control for .NET Suite Download
Please download trial version of KA.Barcode for .NET Suite and unzip it. You are free to use this barcode generator trial version to create UPC-A barcode images in multiple .NET projects without charge for an unlimited period of time. This trial version cannot be used for business applications because a "KA Barcode" watermark will appear on the generated UPC-A barcode image randomly. After you unzip the trial version, you will find:
  • KeepAutomation.Barcode.Windows.dll
  • KeepAutomation.Barcode.Web.dll
  • KeepAutomation.Barcode.SSRS2008CRI.dll
  • KeepAutomation.Barcode.SSRS2008.dll
  • KeepAutomation.Barcode.SSRS2005CRI.dll
  • KeepAutomation.Barcode.SSRS2005.dll
  • KeepAutomation.Barcode.RDLC.dll
  • KeepAutomation.Barcode.Crystal.dll
UPC-A Barcode Creation in .NET Using C# or VB.NET Class
  1. At first, you may add "KeepAutomation.Barcode.Windows.dll" or "KeepAutomation.Barcode.Web.dll" to your project reference.
  2. Then, you can refer to the following C# or VB demo code to create UPC-A barcode image.
C# Sample code
     BarCode upca = new BarCode();
upca.Symbology = KeepAutomation.Barcode.Symbology.UPCA;
upca.CodeToEncode = "01234567891";
upca.generateBarcodeToImageFile("c://upca-csharp.tiff");

VB Sample code
     Dim upca As KeepAutomation.Barcode.Bean.BarCode = New KeepAutomation.Barcode.Bean.BarCode

upca.Symbology = KeepAutomation.Barcode.Symbology.UPCA
upca.CodeToEncode = "01234567891"
upca.generateBarcodeToImageFile("c:/upca-vbnet.tiff")

UPC-A Barcode Generation in ASP.NET Project
  1. Download and unzip the evaluation version online and create a new ASP.NET project.
  2. Easily copy "barcode.aspx" and "barcode.aspx.cs" in "barcode" folder to your project folder.
  3. Add reference "KeepAutomation.Barcode.Web.dll" to your ASP.NET project.
  4. Drag and drop "BarCodeControl" in Toolbox to the aspx page for UPC-A barcode image generation.
  5. Select UPCA barcode type in the Properties panel and run the project to see the created UPC-A barcode image.
Developers can also generate UPC-A barcode image in IIS with this .NET barcode generation control.
  1. Copy the "barcode" folder from the unzipped folder to IIS web application folder.
  2. Create a virtual directory named "barcode", then link it to the "barcode" folder in web application folder
  3. Restart your IIS and navigate to "http://YourDomain:port/barcode/barcode.aspx?symbology=36&code-to-encode=01234567891"(symboloy: UPCA =36, UPCASup2=37, UPCASup5=38).
  4. To add barcodes in html or aspx pages, use the tag below:
    <img src="http://YourDomain:port/barcode/barcode.aspx?symbology=36&code-to-encode=01234567891"(symboloy: UPCA =36, UPCASup2=37, UPCASup5=38)/>
  5. Reset properties of your UPC-A barcode image in the above URL.
UPC-A Barcode Creation in .NET WinForms
  1. Download the trial package of .NET UPC-A barcode dll online and unzip it.
  2. Open your Visual Studio and add KeepAutomation.Barcode.Windows.dll in the unzipped package to the Toolbox.
  3. Just drag and drop the BarCodeControl from the Toolbox into the form.
  4. Choose "UPCA" in "Symbology" under Properties window.
  5. The UCP-A barcode image is created and you can customize it through the Properties window.
UPC-A Barcode Creation in .NET Reports

Insert UPC-A Barcode Image in Crystal Reports
To insert UPC-A barcode image in Crystal Reports, you can use this free evaluation version of .NET barcode creation control and refer to the detailed user guide online.
Add UPC-A Barcode Image in RDLC Reports
To add UPC-A barcode image in RDLC Reports, you can use this free evaluation version of .NET barcode creation control and refer to the detailed user guide online.
Create UPC-A Barcode Image in Reporting Services
To create UPC-A barcode image in Reporting Services, you can use this free evaluation version of .NET barcode creation control and refer to the detailed user guide online.
UPC-A Barcode Generation in .NET Applications with C#
Developers can create advanced UPC-A barcodes in .NET applications using C# class library with this barcode control. A complete generation guide with detailed C# sample code is offered online. Download the evaluation version of this barcode control to generate customized UPC-A barcode images by resetting UPC-A barcode properties.
C# Sample code
     BarCode upca = new BarCode();
// Set barcode symbology type to UPCA, UPCASup2, UPCASup5
upca.Symbology = KeepAutomation.Barcode.Symbology.UPCASup2;
// Set UPC-A encoding code value. Valid input: 0-9. Length: 11 digits without checksum.
upca.CodeToEncode = "11223344551";
// Unit of measure, Pixel, Cm and Inch supported.
upca.BarcodeUnit = BarcodeUnit.Pixel;
// UPC-A image resolution in DPI.
upca.DPI = 72;

//Apply checksum for UPC-A barcode.
upca.ChecksumEnabled = true;
// Display checksum in the UPC-A barcode text
upca.DisplayChecksum = true;

// Set UPC-A image size

// UPC-A bar module width (X dimention), default value is 1 pixel.
upca.X = 2;
// UPC-A bar module height (Y dimention), default is 50 pixel.
upca.Y = 60;
// Image left margin size, 10X is automatically added to go with specification.
upca.LeftMargin = 0;
// Image right margin size, 10X is automatically added to go with specification.
upca.RightMargin = 0;
// UPC-A image top margin size
upca.TopMargin = 0;
// UPC-A image bottom margin size
upca.BottomMargin = 0;
// UPC-A orientation, 90, 180, 270 degrees supported
upca.Orientation = KeepAutomation.Barcode.Orientation.Degree0;

// UPC-A supplement code of 2 or 5 digits
upca.SupplementCode = "02";
// UPC-A supplement bar height vs primary bar height ratio.
upca.SupplementHeight = 0.7f;
// Space between barcode and supplement barcode
upca.SupplementSpace = 15;

// Set UPC-A human readable text style

// Display human readable text
upca.DisplayText = true;
upca.TextFont = new Font("Arial", 10f, FontStyle.Regular);
// Space between barcode and text
upca.TextMargin = 6;

// enerate UPC-A barcodes in image format JPEG
upca.generateBarcodeToImageFile("C://barcode-upca-csharp.jpeg");

/* Create UPC-A barcodes in Stream object
upca.generateBarcodeToStream(".NET System.IO.Stream Object");

Draw & Print UPC-A barcodes to Graphics object
upca.generateBarcodeToGraphics(".NET System.Drawing.Graphics Object");

Generate UPC-A barcodes & write to byte[]
byte[] barcodeInBytes = upca.generateBarcodeToByteArray();

Bitmap barcodeInBitmap = upca.generateBarcodeToBitmap();
*/
Generate UPC-A Using VB.NET Sample Code
This barcode encoder SDK supports UPC-A barcode generation in VB.NET with demo code. The following demo code is free of charge, through which you can change properties of generated UPC-A barcode. Copy the code to your project for testing.
VB Sample code
     Dim upca As KeepAutomation.Barcode.Bean.BarCode = New KeepAutomation.Barcode.Bean.BarCode
upca.Symbology = KeepAutomation.Barcode.Symbology.UPCASup2
upca.CodeToEncode = "22446688001"

'Apply checksum for UPCA barcode.
upca.ChecksumEnabled = True
'Display checksum in UPCA barcode text
upca.DisplayChecksum = True

'UPCA unit of measure, Pixel, Cm and Inch supported.
upca.BarcodeUnit = KeepAutomation.Barcode.BarcodeUnit.Pixel
'UPCA image resolution in DPI.
upca.DPI = 72

'Set UPCA image size

'UPCA bar module width (X dimention)
upca.X = 1
'UPCA bar module height (Y dimention)
upca.Y = 60

'Image left margin size, a 10X is automatically added according to specification.
upca.LeftMargin = 0
'Image right margin size, a 10X is automatically added according to specification.
upca.RightMargin = 0
'UPCA image top margin size'
upca.TopMargin = 0
'UPCA image bottom margin size'
upca.BottomMargin = 0

'UPCA supplemental data settings.
'To enable this, you need to set barcode symbology into "UPCASup2", or "UPCASup5"
'Supplement code. It should be 2 or 5 digits
upca.SupplementCode = "02"
'Supplement bar height vs primary bar height ratio.
upca.SupplementHeight = 0.8F
'Space between barcode and supplement barcode
upca.SupplementSpace = 15


'Orientation, 90, 180, 270 degrees supported' UPCA image bottom margin size
upca.Orientation = KeepAutomation.Barcode.Orientation.Degree0
'UPCA image formats in Png, Gif, Jpeg/Jpg, Tiff, Bmp, etc.
upca.ImageFormat = System.Drawing.Imaging.ImageFormat.Bmp

'Set UPCA human readable text style
upca.DisplayText = True
upca.TextFont = New Drawing.Font("Arial", 10.0F, Drawing.FontStyle.Regular)
'Space between barcode and text
upca.TextMargin = 6

upca.generateBarcodeToImageFile("C://upca-vb-net.bmp")
Free Trial DownloadC#/VB UPC-AFor Web UPC-AFor Windows UPC-AFor Reports UPC-AUsing C#Using VB.NETData Matrix for .NETPDF417 for .NETQR Code for .NETmoreCodabar for .NETCode 39 for .NETCode 128 for .NETEAN-8 for .NETEAN-13 for .NETEAN 128 for .NETIntelligent Mail for .NETInterleaved 2 of 5 for .NETISBN for .NETITF-14 for .NETRM4SCC for .NETUPC-E for .NETmore
KeepAutomation provides complete barcode automation solutions. We recommend the customers use high quality document controls: ASP.NET Document Viewer, ASP.NET MVC Document Viewer, Document Viewer ASP.NET C#, ASP.NET PDF Viewer, ASP.NET Word Viewer, ASP.NET Excel Viewer, ASP.NET PDF Editor, MVC PDF Viewer, ASP.NET Annotate PDF, c# pdf sdk, C# View, edit PDF online , C# Convert PDF to Tiff, C# Convert PDF to text, txt, .net imaging sdk, C# PDF metadata edit from RasterEdge.com.