Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid / corrupted QR Code #330

Closed
Armin234 opened this issue Oct 6, 2021 · 2 comments · Fixed by #339
Closed

Invalid / corrupted QR Code #330

Armin234 opened this issue Oct 6, 2021 · 2 comments · Fixed by #339

Comments

@Armin234
Copy link

Armin234 commented Oct 6, 2021

Hi,

I'm using .Net 4.5 und Nuget version 1.4.1 of QRCoder, and I'm getting an invalid / corrupted
QR-Code for the Data = "A11".
The generated QR-Code has only 20 Lines, instant of 21 lines as the QR-code generated for "A05"

QRCodeGenerator qrGenerator = new QRCodeGenerator();
QRCodeData qrCodeData = qrGenerator.CreateQrCode("A11" , QRCodeGenerator.ECCLevel.H);
AsciiQRCode qrCode = new AsciiQRCode(qrCodeData);

string lF = qrCode.GetGraphic(1, "1", "0", "\n");

Is there any workaround ?

Regards Armin

@victoriensukarieh
Copy link

when using the & in the string the code is altered. do you have a similar issue?

codebude added a commit that referenced this issue Nov 8, 2021
Empty lines were falsely removed. (I guess the author initially wanted to remove the whitespace around the QR code. I will add a flag to suppress whitespace in another commit.)
@codebude
Copy link
Owner

codebude commented Nov 8, 2021

Thank you both for your input! I found and fixed the bug in #339
If you want to test the changes, feel free to use the latest CI-build nuget package (Should be available within 10 minutes.) or wait for the 1.4.2 release on Nuget.org.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants