C#: Online Guide
How To: Barcode Generator
UPC-E
UPC-E
  |  
Home ›› XImage.Barcode Generator ›› VB Barcode Generator: UPC-E

VB Imaging - UPC-E Generator DLL Control


Create UPC-E & Insert Generated Barcode into Document Image in VB




VB Imaging - UPC-E Generator SDK Overview



In the download package of DocImage SDK for .NET, you may find a mature VB.NET barcode generation dll, RasterEdge.Imaging.Barcode.Creator.dll, which is highly-rated UPC-E barcode generating library. Its perfect integration with VB.NET image and document processing & modifying projects makes it quite popular in daily-life applications for UPC-E linear barcode generation. itextsharp how to create pdf with a table design and embed image in c#, c# pdf add bookmark, vb.net convert pdf to text file, c# pdf metadata, vb.net read pdf file contents, vb.net pdf reader, c# draw pdf.


Related .net document control helps:
asp.net edit pdf text: ASP.NET PDF Text Edit Control: online edit PDF text content using C# ASP.NET
asp.net document viewer c#: ASP.NET Document Viewer using C#: Open, View, Annotate, Redact, Convert document files in ASP.NET using C#, HTML5, JQuer...
asp.net image viewer: ASP.NET Image Viewer Control(MVC & WebForms): view, annotate, redact, convert image files in html, JQuery
asp.net pdf viewer: ASP.NET PDF Viewer Control: view, navigate, zoom Adobe PDF document in C# ASP.NET
asp.net sharepoint document viewer: ASP.NET SharePoint Document Viewer: view, annotate, redact documents in SharePoint
asp.net powerpoint viewer: ASP.NET PowerPoint Document Viewer Control (MVC & WebForms): view ppt, pptx files online in C# using ASP.NET
asp.net word viewer: ASP.NET Office Word Document Viewer: view Word doc files online using C# in ASP.NET MVC web applications


RasterEdge VB.NET UPC-E Barcode Add-on toolkit is a stable and reliable .NET barcode SDK library, which empowers VB programmers and end users with maximized capabilities to implement high quality UPC-E barcode generation features into Visual Studio (2005, 2008, 2010 & 2012) VB.NET applications. asp.net mvc create pdf from view, asp net replace text fro pdf free, preview pdf in asp.net mvc, open word document in iframe using asp.net, pdf editor asp.net, how to display pdf file in asp.net c#, asp.net tiff image viewer.


With this VB.NET UPE-E barcoding component, UPC-E barcode can be created, saved and printed as graphic image and document in gif, tiff, bmp, png, jpeg, PDF and Word formats.


Please look at the layout of this VB.NET UPC-E barcoding tutorial page:


General features and techs list of UPC-E barcode creation for VB.NET


Using VB.NET code to create & write UPC-E barcode on image file


Using VB.NET code to encode & draw UPC-E barcode on document file


Using VB.NET code to generate & draw UPC-E barcode with desired property values


Primary UPC-E information within VB.NET application


Fully managed .NET imaging barcode creating APIs are totally compatible within VB class and Console Applications


Support inserting UPC-E barcode in .NET report applications, like RDLC Report and Crystal Report


Comprehensive UPC-E barcode generating library in VB supports customizing all related size and color parameters


Able to add and specialize UPC-E barcode human-readable text with simple VB demo code


Enable VB programmer to rotate UPC-E barcode (0, 90, 180 or 270 degree) to meet specific requirements


Competent to save barcode as byte stream object as well as various image format files with mature VB.NET image output methods


Support printing UPC-E barcode image from VB.NET projects by almost all printers




VB Code for Customizing UPC-E Barcode Generation



You can easily generator UPC-E barcode and save it  to image files/object using this VB.NET barcode generator control. The following steps will show how to create a UPC-E type barcode encoding numeric data text "012345" into the image object with XImage.Barcode.Creator.


Add References


  RasterEdge.Imaging.Basic.dll


  RasterEdge.Imaging.Drawing.dll


  RasterEdge.Imaging.Font.dll


  RasterEdge.Imaging.Processing.dll


  RasterEdge.XImage.BarcodeCreator.dll


  System.Drawing.dll


Using Namespaces


  using System.Drawing;


  using RasterEdge.XImage.BarcodeCreator;


Note: When you get the error "Could not load file or assembly 'RasterEdge.Imaging.Basic' or any other assembly or one of its dependencies. An attempt to load a program with an incorrect format", please check your configure as follows:

       

       If you are using x64 libraries/dlls, Right click the project -> Properties -> Build -> Platform target: x64.

       

       If using x86, the platform target should be x86.


Please copy the sample code as follow to generator a UPC-A barcode.




'create a barcode
Dim barcode As Linear = New Linear()
'select barcode type
barcode.Type = BarcodeType.UPCE
'set barcode data
barcode.Data = "012345"
'set x,y position
barcode.X = 1.0F
barcode.Y = 60.0F
'set resolution
barcode.Resolution = 96
'set rotation
barcode.Rotate = Rotate.Rotate0
barcode.BarcodeWidth = 200
barcode.BarcodeHeight = 200
barcode.AutoResize = true

'convert barcode to a bitmap and save it to image file
'Dim bmp As Bitmap = barcode.ToImage()
'bmp.Save("C:\\barcode.bmp")





Add UPC-E Barcode to Image in VB



As mentioned above, RasterEdge UPC-E VB barcode creator DLL can generate UPC-E barcode and draw created UPC-E on BMP, PNG, GIF, JPEG image files. Here we offer a VB programming example to explain how to draw standard UPC-E barcode on a PNG image file.




Dim image As REImage  = New REImage("C:\\Sample.png")
barcode.DrawBarcode(image, 150F, 150F)
image.Save(ImageType.PNG, "C:\\Sample_Barcode.png")





How to Insert UPC-E into Document in VB



Here, we offer some VB codes for you to have a better understanding of UPC-E barcode creation and insertion on source document files, including PDF, TIFF, Word, Excel and PowerPoint.



VB.NET UPC-E Barcode Generation on PDF Page



Add References(Extra)


  RasterEdge.Imaging.Basic.Codec.dll


  RasterEdge.XImage.Raster.dll


  RasterEdge.XImage.Raster.Core.dll


  RasterEdge.XDoc.PDF.dll


Using Namespace(Extra)


  RasterEdge.XDoc.PDF;


  RasterEdge.Imaging.Basic;


  RasterEdge.Imaging.Raster.Core;



Dim  docx As PDFDocument = New PDFDocument("C:\\Sample.pdf")
Dim  page As PDFPage = docx.GetPage(0)
Dim  image As Bitmap = barcode.ToImage() 'Define on the above code
page.AddImage(image, New PointF(100F, 100F))
docx.Save("C:\\Sample_Barcode.pdf")




VB.NET UPC-E Barcode Drawing on TIFF Page



Add References(Extra)


  RasterEdge.Imaging.Basic.Codec.dll


  RasterEdge.XImage.Raster.dll


  RasterEdge.XImage.Raster.Core.dll


  RasterEdge.XDoc.TIFF.dll


Using Namespace(Extra)


  RasterEdge.XDoc.TIFF;


  RasterEdge.Imaging.Basic;


  RasterEdge.Imaging.Raster.Core;




Dim  docx As TIFFDocument = New TIFFDocument("C:\\Sample.tif")
Dim page As BasePage = docx.GetPage(0)
Dim  image As REImage = New REImage(barcode.ToImage())
page.AddImage(image, New PointF(100F, 100F))
docx.Save("C:\\Sample_Barcode.tif")




VB.NET UPC-E Barcode Creation on Word Page



Add References(Extra)


  RasterEdge.XDoc.Word.dll


  RasterEdge.XImage.Raster.dll


  RasterEdge.XImage.Raster.Core.dll


  RasterEdge.XDoc.Office.Inner.Common.dll


  RasterEdge.XDoc.Office.Inner..Office03.dll


Using Namespace(Extra)


  RasterEdge.XDoc.Word;


  RasterEdge.Imaging.Basic;


  RasterEdge.Imaging.Raster.Core;




Dim  docx As DOCXDocument = New DOCXDocument("C:\\Sample.docx")
Dim page As BasePage = docx.GetPage(0)
Dim  image As REImage = New REImage(barcode.ToImage())
page.AddImage(image, New PointF(100F, 100F))
docx.Save("C:\\Sample_Barcode.docx")




Generate UPC-E Barcode on Excel Sheet in VB.NET



Add References(Extra)


  RasterEdge.XDoc.Excel.dll


  RasterEdge.XImage.Raster.dll


  RasterEdge.XImage.Raster.Core.dll


  RasterEdge.XDoc.Office.Inner.Common.dll


  RasterEdge.XDoc.Office.Inner..Office03.dll


Using Namespace(Extra)


  RasterEdge.XDoc.Excel;


  RasterEdge.Imaging.Basic;


  RasterEdge.Imaging.Raster.Core;




Dim  docx As XLSXDocument = New XLSXDocument("C:\\Sample.xlsx")
Dim page As BasePage = docx.GetPage(0)
Dim  image As REImage = New REImage(barcode.ToImage())
page.AddImage(image, New PointF(100F, 100F))
docx.Save("C:\\Sample_Barcode.xlsx")




Add and Burn UPC-E Barcode Image to PPTX in VB.NET



Add References(Extra)


  RasterEdge.XDoc.PowerPoint.dll


  RasterEdge.XImage.Raster.dll


  RasterEdge.XImage.Raster.Core.dll


  RasterEdge.XDoc.Office.Inner.Common.dll


  RasterEdge.XDoc.Office.Inner..Office03.dll


Using Namespace(Extra)


  RasterEdge.XDoc.PowerPoint;


  RasterEdge.Imaging.Basic;


  RasterEdge.Imaging.Raster.Core;




Dim  docx As PPTXDocument = New PPTXDocument("C:\\Sample.pptx")
Dim page As BasePage = docx.GetPage(0)
Dim  image As REImage = New REImage(barcode.ToImage())
page.AddImage(image, New PointF(100F, 100F))
docx.Save("C:\\Sample_Barcode.pptx")





Complete VB Code for UPC-E Generation on Document & Image



The sample VB code below aims to illustrate how to create and insert a fully user-customized UPC-E barcode on target image file using VB.NET programming method.




'create REImage on which you want to draw the barcode
Dim reImage As REImage = New REImage("c:/Sample.png")

'create a barcode
Dim barcode As Linear  = New Linear()
'select barcode type
barcode.Type = BarcodeType.UPCE
'set barcode data 
barcode.Data = "012345"

'UPC-E barcode size related
'set x,y position
barcode.X = 1.0F
barcode.Y = 60.0F
barcode.BarcodeHeight = 60
barcode.BarcodeWidth = 0
barcode.BottomMargin = 0
barcode.LeftMargin = 0
barcode.RightMargin = 0
barcode.BarAlignment = AlignmentHori.Center
'set resolution
barcode.Resolution = 72
'set rotation
barcode.Rotate = Rotate.Rotate0
barcode.AddCheckSum = false
barcode.UOM = UnitOfMeasure.PIXEL

'UPC-E colors
barcode.BackColor = System.Drawing.Color.White
barcode.ForeColor = System.Drawing.Color.Black

'UPC-E font style
 barcode.TextFont = New Font("Arial", 9f, FontStyle.Regular)
barcode.TextColor = System.Drawing.Color.Black
barcode.TextMargin = 6
barcode.ShowText = true

'UPC-E special
'barcode.SupData = ""
'barcode.SupHeight = 0.8f
'barcode.SupSpace = 15f

'draw barcode on REImage with location x and y
barcode.DrawBarcode(reImage, 0, 0)

reImage.Save(ImageType.PNG, "c:/barcode.png")