Skip to main content
All docs
V26.1
  • Micro QR Code

    • 2 minutes to read

    Micro QR Code is a compact version of QR Code that encodes up to 35 numeric or 21 alphanumeric characters. It fits space-constrained labels used in electronics, medical devices, and retail.

    View Example

    Examples

    Configure Barcode Settings (MicroQRCodeOptions)

    Use the MicroQRCodeOptions class to configure Micro QR Code barcode settings.

    The following code snippet creates the Micro QR Code barcode and specifies its settings:

    DevExpress Barcode Generator - Micro QR Code barcode

    using DevExpress.Docs.Barcode;
    using DevExpress.Drawing;
    using System.Drawing;
    
    var microQrOptions = new MicroQRCodeOptions();
    microQrOptions.CompactionMode = MicroQRCodeCompactionMode.Byte;
    microQrOptions.ErrorCorrectionLevel = MicroQRCodeErrorCorrectionLevel.Auto;
    microQrOptions.BackColor = Color.LightGray;
    microQrOptions.ShowText = false;
    microQrOptions.Padding = new Padding(5);
    microQrOptions.BorderWidth = 1;
    microQrOptions.BorderColor = Color.Blue;
    
    using var microQrOptionsStream = new FileStream(Path.Combine(outDir, "barcode_symbology_micro_qr_code.png"), FileMode.Create, FileAccess.Write);
    using var microQrOptionsGenerator = new BarcodeGenerator(microQrOptions);
    microQrOptionsGenerator.Export("HELLO123", microQrOptionsStream, DXImageFormat.Png);
    

    Configure Barcode Settings (Fluent API)

    Use the MicroQRCodeOptionsBuilder class to configure Micro QR Code barcode settings with Fluent API.

    The following code snippet creates the Micro QR Code barcode and specifies its settings:

    DevExpress Barcode Generator - Micro QR Code barcode

    using DevExpress.Docs.Barcode;
    using DevExpress.Drawing;
    using System.Drawing;
    
    var microQRCode = MicroQRCodeOptionsBuilder.Create()
        .WithCompactionMode(MicroQRCodeCompactionMode.Byte)
        .WithErrorCorrectionLevel(MicroQRCodeErrorCorrectionLevel.Auto)
        .WithBackColor(Color.LightGray)
        .WithShowText(false)
        .WithPadding(5)
        .WithBorderWidth(1)
        .WithBorderColor(Color.Blue)
        .Build();
    
    var filePath = Path.GetFullPath("microQr_barcode.png");
    
    using var stream = new FileStream(filePath, FileMode.Create);
    using var generator = new BarcodeGenerator(microQRCode);
    generator.Export("HELLO123", stream, DXImageFormat.Png);
    

    Symbology-Specific Options

    Property Description
    CompactionMode Specifies the compaction mode.
    ErrorCorrectionLevel Specifies the error correction level.
    IncludeQuietZone Specifies whether to include a quiet zone (a margin of empty space) around the code.
    Version Gets or sets the Micro QR Code version.
    See Also