We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

QR code physical dimensions?

Thread ID:

Created:

Updated:

Platform:

Replies:

130457 May 14,2017 02:07 PM May 15,2017 08:13 AM Xamarin.Forms 2
loading
Tags: PDF
Slobodan Babic
Asked On May 14, 2017 02:07 PM

Hello everyone.

I would like to generate a PDF file with more pages, each page same (custom) size, and only one QR code per page, filling the entire page.
PDF will be manipulated later, so physical dimension of single code's square is not important - just the size of the rendered QR code.

Is there a way of knowing how big will the generated QR code be on PDF page? 
I tried reading barcode.Size.Width and barcode.Size.Height properties (both before and after barcode.Draw was executed), but I am always getting zeroes.

Cheers.

Slobodan Babic
Replied On May 14, 2017 02:41 PM

I just figured it out.

barcode.Size = new SizeF(100, 100);

will generate QR code of size 100×100, no matter how long the Text is, or what you do with XDimension and PdfErrorCorrectionLevel.
Of course, individual squares generated will be smaller as Text gets longer…

Did not want to delete thread - may be useful for someone else.


Gayathri Ramalingam [Syncfusion]
Replied On May 15, 2017 08:13 AM

Hi Slobodan, 
 
Thank you for using Syncfusion product. 
 
Please find the details of your queries in the below table, 
Query 
Details 
Is there a way of knowing how big will the generated QR code be on PDF page?  
I tried reading barcode.Size.Width and barcode.Size.Height properties (both before and after barcode.Draw was executed), but I am always getting zeroes. 
Currently we do not have support to getting size of the QRBarcode in Xamarin.Forms, we will consider this usability feature request. We will implement this feature and it will be included in our Volume 2, SP 1 release which is expected to be available at the end of May, 2017.   We request you to visit our website periodically for feature related updates.  
 
 
 
what you do with XDimension andPdfErrorCorrectionLevel. 
XDimension: 
Specifies the width of the narrowest element(bar or space) in a barcode. The greater the x dimension, the more easily a barcode reader will scan. 
 
Error Correction Level: 
There are 4 error correction levels used for QR codes, with each one adding different amounts of “backup” data depending on how much damage the QR code is expected to suffer in its intended environment, and hence how much error correction may be required: 
  • Level L – up to 7% damage
  • Level M – up to 15% damage
  • Level Q – up to 25% damage
  • Level H – up to 30% damage
Please find the below link for more details about Error correction level, 
 
Please let us know if you need further assistance on this. 
 
With Regards, 
Gayathri R 
 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;