C#. Code 2 of 5 Generator Image Setting Tutorial

sample source code to generate linear Code 2 of 5 in png, jpeg, etc. image formats in C# .NET


 

C# Code 2 of 5 Introduction

Code 2 of 5, also known as Standard 2 of 5, Industrial 2 of 5, is a low-density numeric symbology that has been widely used in warehouse, photo finishing and airline industries.

C# Code 2 of 5 is barcode generation dill for .NET programming. It can easily generate Code 2 of 5 images in various .NET platforms, such as ASP.NET barcode generator web control, .NET Winforms barcode generator control and Reporting service barcode generation component. Various image formats, image resolution, image rotation properties allows for easy integration. For example, image formats can be adjusted among tiff, bmp, png, gif and jpeg.

OnBarcode C# Barcode Generator is designed to generate, create Code 2 of 5 and other linear & 2d barcodes in Microsoft Word. Here are some more tutorials for C# Code 2 of 5 generation concerning data encoding and size setting.

 

C#.NET Code 2 of 5 Image Format Setting

C# .NET Code 2 of 5 image format setting supports 5 image formats during generating Code 2 of 5 in C# programming:

Linear code25 = new Linear();

code25.Type = BarcodeType.CODE25;

code25.Data = "252525";

Generating Code 2 of 5 in PNG Format

You may set the PNG format to generate Code 2 of 5 images in C#.NET Class & console application:

code25.Format = ImageFormat.Png;

code25.drawBarcode("c:\Code 2 of 5.png");

Creating Code 2 of 5 in JPEG Format

You may set the JEPG format to generate Code 2 of 5 images in C# ASP.NET web projects:

cde25.Format = ImageFormat.Jpeg;

code25.drawBarcode("c:\Code 2 of 5.jpeg");

Drawing Code 2 of 5 in Gif Format

You may set the GIF format to generate Code 2 of 5 images in C#.NET Windows Forms programming:

code25.Format = ImageFormat.Gif;

code25.drawBarcode("c:\Code 2 of 5.gif");

Creating Code 2 of 5 in Tiff Format

You may set the TIFF format to generate Code 2 of 5 images in SQL Server Reporting Service (SSRS) & Crystal Reports:

code25.Format = ImageFormat.Tiff;

code25.drawBarcode("c:\Code 2 of 5.tiff");

Creating Code 2 of 5 in BMP Format

You may set the BMP format to generate Code 2 of 5 images in C# class.:

code25.Format = ImageFormat.Bmp;

code25.drawBarcode("c:\Code 2 of 5.bmp");

 

C#.NET Code 2 of 5 Image Rotation Setting

C# .NET Code 2 of 5 image rotation setting supports rotating the generated Code 2 of 5 image with 0, 90, 180, 270 degrees in C# projects:

Linear code25 = new Linear();

code25.Type = BarcodeType.CODE25;

code25.Data = "1234";

barcode.Rotate = Rotate.Rotate270;

 

C#.NET Code 2 of 5 Image Resolution Setting

C# .NET Code 2 of 5 image resolution setting allows setting the resolution for the created image in C# programming:

Linear code25 = new Linear();

code25.Type = BarcodeType.CODE25;

code25.Data = "456";

code25.Resolution = 110;

 

C#.NET Code 2 of 5 Image Color Setting

C# .NET Code 2 of 5 image color can be easily integrated with changing the text color, background color and bar color when generating Code 2 of 5 in C# class:

Linear code25 = new Linear();

code25.Type = BarcodeType.CODE25;

code25.Data = "123";

code25.BackColor = Color.Red;

code25.ForeColor = Color.Blue;

code25.TextColor = Color.Yellow;

 

C#.NET Code 25 Bar Alignment Setting

Bar Alignment property are available for C#.NET Code 25 image setting:

Linear code25 = new Linear();

code25.Type = BarcodeType.CODE25;

code25.Data = "12445";

code25.BarcodeWidth=300;

code25.BarAlignment = AlignmentHori.Left;

When the set image width is larger than the minimum image width, Bar Alignment property can set the extra space on the left, center and right side.







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.