QR Code inside Report

Hi

I need to generate a QR Code and print it inside a report
From what I managed to understand from the documentation I have to:

  1. generate de QR image
    Java: Simple QR Code Generator Example - Create QR codes for free • Crunchify produces a BufferedImage
  2. save the Image inside a FileDescriptor field on my entity
    how do I programatically save the file generated at step 1?
  3. format the image inside the report with ${imageFileId:WxH}
  4. load the entity and generate report

Is this correct? can it be done easier?

Thank you

Hi George,

You can find the working example in my sample application here. Generally, the application uses the zxing library to generate barcodes and QR codes. The application provides the service to generate QR codes (both, byte array and file descriptor). The [DOCX2PDF] Invoice report is using this service to get the byte array of the QR code image and insert it into the report.

Regards,
Aleksey

1 Like

Thank you!