C# QR Code Image Generator Library
How to generate QR Code 2d barcode with high resolution, raster, vector, transparency image file in C# ASP.NET Core, Windows apps

Create high quality QR Code barcode vecter, raster images on TIFF, PDF, Word, Excel and PowerPoint document using C#

In this C# tutorial, you will learn how to create a QR Code 2d barcode with advanced image option settings using C# in ASP.NET MVC Web, Windows applications.

  • Generate high resolution QR Code barcode images for printing
  • Advanced options for barcode module color, and transpanrent background
  • Draw, print QR Code in PNG, JPG, and Bitmap raster images, SVG and EPS vector images.
  • Create QR Code in PDF, TIFF, Office Word, Excel, PowerPoint files

How to create a QR Code in JPG, PDF, Tiff, Word, BMP file using C#

  1. Download XImage.Barcode Generator C# library
  2. Install C# library to draw QR Code barcodes
  3. Step by Step Tutorial

QR Code Image Formats Supported

RasterEdge C# QR Code barcode generator library supports the following raster image formats:

Raster Image Formats

  • Bitmap
  • Jpg
  • Png
  • Gif
  • TIFF

Vector Image Formats

  • SVG
  • EPS

You will create QR Code barcode image file through method QRCode.DrawBarcode() with output OutputFileType applied.

OutputFileType supports: BMP, GIF, JPG, PNG, TIF, SVG, EPS.

  void DrawBarcode(String filePath, OutputFileType fileType)
  void DrawBarcode(Stream stream, OutputFileType fileType)
  byte[] DrawBarcode(OutputFileType fileType)

How to generate QR Code barcode with color and transparency background image using C# code?

Usually QR Code barcode is bar module in black color and white background color. However if you need create QR Code barcode in different colors, you could easily apply the color settings in class QRCode using C# QRCode Generator library.

  • ForeColor : Define the QR Code bar mudule colors. The default value is Color.Black.
  • BackColor: Define the QR Code background color. The default value is Color.White.

            barcode.ForeColor = Color.Red;
            barcode.BackColor = Color.Green;

QR Code with transparent background

To create QR Code image with transparent background, you need set property BackColor value to Color.Transparent

            barcode.ForeColor = Color.White;
            barcode.BackColor = Color.Transparent;

How to create high resolution QR Code image for printing using C# code?

If your generated QR Code barcodes will be printed, the QR Code image resolution should be larger than the printer's.

The following C# source code explains how to set QR Code barcode image resolution in C# class.

            barcode.Resolution = 3000;

How to generate rotated QR Code barcode image C# code?

To create rotated QR Code barcode image, you need apply the property Rotate in class QRCode in your C#.net code.

  • Rotate: All available values: Rotate0, Rotate90, Rotate180, Rotate270, which will rotate 0 degree, 90 degree, 180 degree, and 270 defree.

            barcode.Rotate = Rotate.Rotate180;