PDF417 Barcode Printing in SSRS D365FO

PDF417 Barcode Printing in SSRS D365FO

Hi,

After long struggle I have found PDF417 barcode print in D365FO

Steps in Detail

Step 1: Download Open source dll PDF417 Encoder Library dll

https://www.codeproject.com/Articles/1347529/PDF417-Barcode-Encoder-Class-Library-and-Demo-App

Step 2: Include above DDL in your Extensions BIN Folder and Visual Studio Project bin Folder

1.     paste the DLL to your AX extension Bin Folder so we can use it in our AX project.

2.     Just build your project then go to your projects bin\Debug folder and copy Dll


Step 3: Add Reference to Project

Right click on Project and Add Reference and Browse and Add the dll

Step 4: DP Class in report

1. Using Pdf417EncoderLibrary; // In Header Section in Header section above class start

2. Add Bitmap field in report table like bitmapPDF417BarCode

3. Modify below code as per requirement 

 

Inside the process method

 

        str PDF417Data="TESTPDF417BARCODEinD365FOSSRSReport"

 

      //  // create PDF417 barcode object

        Pdf417BarcodeEncoder   Encoder = new Pdf417BarcodeEncoder();

 

      //  // change default data columns

        Encoder.DefaultDataColumns = 4;

 

      //  // encode barcode data

        Encoder.Encode(PDF417Data);

        System.Drawing.Bitmap  bitMapImage;

        bitMapImage= Encoder.CreateBarcodeBitmap();

 

       container imageContainer;

  

        using (System.IO.MemoryStream stream = new System.IO.MemoryStream())

        {

            bitMapImage.Save(stream, System.Drawing.Imaging.ImageFormat::Png );

            imageContainer= Binary::constructFromMemoryStream(stream).getContainer();

        }

 

        YOURTempTableTmp.bitmapPDF417BarCode=imageContainer;

 

             YOURTempTableTmp.Insert();


 Step 5: Add New Bitmap field in report and embedded the new field as database field

Output will be like below 



1. 


Comments

  1. It is a great website and has a nice article. I want to thank you. Good job! You guys do a great blog, custom erp company in chennai

    ReplyDelete

Post a Comment