- Home
- Products
- Integration
- Tutorial
- Barcode FAQ
- Purchase
- Company
C# QR Code Generator Library SDK Integration & Developer GuideGenerate 2d barcode QR Code images in Visual C# .NET with complete sample C# source code
Index
C# QR-Code Generator Introduction
C# QR Code Generator is one of the functions in OnBarcode's
Barcode for .NET Generation Controls, which supports
generating & printing QR Code and 20+ other linear & 2D bar codes for C# applications.
QR Code Generator library, SDK & application OnBarcode provides several QR Code Generator components and software, including QR Code .NET, QR Code Java, QR Code VB.NET, QR Code ASP.NET, QR Code iPhone, QR Code iPad, QR Code Android, QR Code Generator. This document is providing a detailed C# source code about generating QR Code barcodes in C# class using C# Barcode generation component. Complete QR Code custmoization settings is included in C# QR Code generation guide. Create QR-Code Barcodes in C#Creating QR-Code barcode in C# class example: using System; using System.Collections.Generic; using System.Text; using OnBarcode.Barcode; using System.Drawing.Imaging; using System.Drawing; QRCode qrcode = new QRCode(); // Barcode data to encode qrcode.Data = "ONBARCODE"; // QR-Code data mode qrcode.DataMode = QRCodeDataMode.AlphaNumeric; // QR-Code format mode //qrcode.Version = QRCodeVersion.V10; /* * Barcode Image Related Settings */ // Unit of meature for all size related setting in the library. qrcode.UOM = UnitOfMeasure.PIXEL; // Bar module size (X), default is 3 pixel; qrcode.X = 3; // Barcode image left, right, top, bottom margins. Defaults are 0. qrcode.LeftMargin = 0; qrcode.RightMargin = 0; qrcode.TopMargin = 0; qrcode.BottomMargin = 0; // Image resolution in dpi, default is 72 dpi. qrcode.Resolution = 72; // Created barcode orientation. 4 options are: facing left, facing right, facing bottom, and facing top qrcode.Rotate = Rotate.Rotate0; // Generate QR-Code and encode barcode to gif format qrcode.ImageFormat = ImageFormat.Gif; qrcode.drawBarcode("C:\\barcodeimages\\qrcode.gif"); /* You can also call other drawing methods to generate barcodes public void drawBarcode(Graphics graphics); public void drawBarcode(string filename); public Bitmap drawBarcode(); public void drawBarcode(Stream stream); */ More C# Barcode Generation Tutorials: |