NavWithNav

The premier knowledge-sharing hub for Microsoft Dynamics 365 Business Central developers, architects, and ERP professionals.

Back to Series
Uncategorized

Print QR Code in PaySlip with LS Retail NAV 2016

I found one of the the method and DLL file which is being used in below code to generate the particular width and height of the QR code in Pay slip. <b>Note: please check your thermal or Zebra prin...

NitinSeptember 23, 2022 1 min read
Business CentralAL ProgrammingBarcodeReports
I found one of the the method and DLL file which is being used in below code to generate the particular width and height of the QR code in Pay slip. <b>Note: please check your thermal or Zebra printer setting to print QR code image.</b> &nbsp; <b>Declarations of Variables</b> Name DataType Subtype Length EncodingOptionDotNetZXing.Common.EncodingOptions.'zxing, Version=0.16.6.0, Culture=neutral, PublicKeyToken=830ae994e36ac27d' BarcodeWriterDotNetZXing.BarcodeWriter.'zxing, Version=0.16.6.0, Culture=neutral, PublicKeyToken=830ae994e36ac27d' BarcodeformatDotNetZXing.BarcodeFormat.'zxing, Version=0.16.6.0, Culture=neutral, PublicKeyToken=830ae994e36ac27d' BitMatrixDotNetZXing.Common.BitMatrix.'zxing, Version=0.16.6.0, Culture=neutral, PublicKeyToken=830ae994e36ac27d' QrCodeBitmapDotNetSystem.Drawing.Bitmap.'System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' ImageFormatDotNetSystem.Drawing.Imaging.ImageFormat.'System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' <a href="https://navgroupinclusive-my.sharepoint.com/:f:/g/personal/ngi_navgroupinclusive_onmicrosoft_com/Ekd7_s7U8ptBkKTs0cPuBLgB1Mp7FIAJJFP0OsIDr_Claw?e=aB6Wcf" target="_blank" rel="noopener">Zing DLL download here.</a> LOCAL <b>GenerateQRCode</b>(TexttoQR : Text) QRPath : Text EncodingOption := EncodingOption.EncodingOptions(); EncodingOption.Height := 200; EncodingOption.Width := 200; &nbsp; BarcodeWriter := BarcodeWriter.BarcodeWriter(); BarcodeWriter.Format := Barcodeformat.QR_CODE; BarcodeWriter.Options := EncodingOption; BitMatrix := BarcodeWriter.Encode(TexttoQR); QrCodeBitmap := BarcodeWriter.Write(BitMatrix); &nbsp; ServerFileName:=COPYSTR(FileManagement.ServerTempFileName(BmpFormat),1,250); QrCodeBitmap.Save(ServerFileName, ImageFormat.Bmp); ClientFileName:=FileManagement.ClientTempFileName(''); FileManagement.DownloadToFile(ServerFileName,ClientFileName); &nbsp; FileManagement.BLOBImport(TempBlob,ClientFileName); &nbsp; FileManagement.BLOBImportFromServerFile(TempBlob, ClientFileName); QRPath := FileManagement.BLOBExport(TempBlob, 'InvQrCode.jpg',FALSE); EXIT(QRPath);
0
0

Discussion (0)

Leave a comment

No comments yet. Be the first to share your thoughts!

Newsletter

Stay updated with the latest Business Central development tips.

Nitin Verma

Nitin Verma

Solution Architect

Extensive experience specializing in Microsoft Dynamics NAV, Business Central, Power Platform, and ERP Architecture.

Read full bio

Search Articles

Monthly Archive

Loading...

Visitor Stats