Spire.Barcode is a professional barcode library specially designed for .NET developers (C#, VB.NET, ASP.NET, .NET Core) and Java developers (J2SE and J2EE) to generate, read and scan 1D & 2D barcodes.

Fri Feb 12, 2016 11:28 am

When I try to create a Pdf417 barcode, I get a black rectangle. I can't figure out what values I need to set and nothing is documented. Would someone post a sample that shows how to create a Pdf417 barcode? Extra credit if the fields are explained.


Posts: 5
Joined: Sat Feb 06, 2016 1:05 pm

Sun Feb 14, 2016 7:31 am


Thanks for using our component.
Please try the following code.
Code: Select all
 string id = "123456";
            BarcodeSettings setting = new BarcodeSettings();
            setting.Data2D = id;
            setting.Data = id;
            setting.Type = BarCodeType.Pdf417;

            setting.ShowText = false;

            BarCodeGenerator generator = new BarCodeGenerator(setting);

            Image barcode = generator.GenerateImage();


Best Regards,
E-iceblue support team
User avatar

Posts: 2448
Joined: Wed Jun 27, 2012 8:50 am

Return to Spire.BarCode