Share this post on:


Recently there were some topics about generating qr code offline and storing on device and thus I got idea to create Qr extension.
It basically creates and reads qr and bar codes offline from file.

Latest Version: 5
Released: March 21, 2020
Last Updated: April 22, 2021



A short documentation for the extension…

  • Bar Code Decoded
    Event raised after decoding bar code with result and barcode’s format

    result ~ text
    barFormat ~ text
  • Bar Code Generated
    Event raised after GenerateBarCode method with response and filepath.If any error occurred during encoding then filePath value will be empty.

    response ~ text
    filePath ~ text
  • Barcode Formats
    Returns a list of barcode formats which can be either encoded or decoded.Some formats can be encoded and decoded both like QR_CODE and CODE_39.

    Returns : List< String >
  • Decode Bar Code
    Tries to decode barcode from file from given path.

    filePath ~ text
  • Generate Bar Code
    Generates barcode to given path with provided hints.

    text ~ text
    filePath ~ text
  • height ~ int
  • width ~ int
    fileFormat ~ text
    barFormat ~ text
    charset ~ text
    margin ~ int
    bgColor ~ int (Color)
    barColor ~ int (Color)

Note: Unfortunately the extension is unable to work without having Barcode Scanner component dependencies so you will have to add a barcode scanner component besides this extension


Download Link: com.sunny.qr.aix (15.1 KB)


ChangeLog Version2

Bug Fixes/Changes

  • Replaced relative filePath with abstract filePath in DecodeQrCode and DecodeBarCode methods.But both Generate methods still use relative filePath.

ChangeLog Version3

New methods

  • Added BarcodeFormats method


  • Removed some Qr related methods and events.Now you can generate qr using GenerateBarCode method by using QR_CODE as barFormat.
  • Now it will automatically ask for Read and Write permissions if they are not granted/disabled.

ChangeLog Version4


  • Added logoPath parameter in GenerateBarCode method
  • Changed package name to com.sunny.qr from com.sunny.Qr
  • The extension does not ask for any permission and uses absolute file paths

ChangeLog Version5

New blocks
Normally should not be used


  • Removed redundant barFormat param from DecodeBarCode method
  • Added barFormat param in BarCodeDecoded event

Bug Fixes

  • Fixed assets logo issue in GenerateBarCode method
Notify of
Newest Most Voted
Inline Feedbacks
View all comments
Gustavo Niederauer
1 year ago

Is there a way to create a Document scanner extension(PDF creator)? I need to scan documents, but don’t want to use the camera tool.

Ekansh Pandit
1 year ago

i have i doubt that if it is like zxing view extension . if yes then i will use this cuz i like ur extensions

1 year ago

This extension has only bar code blocks only. Do they work for QR codes as well?