Recently someone asked me how to print barcodes in a Dynamics NAV RDLC report. And I hade done something similar, years ago in NAV2009. So I had a look at my code and updated it to NAV 2015.

As you can see, it still works:

barcode1

Usually a barcode is no more then a font you need to select, and maybe first download and install. But sometimes it does not work of is not available for all fonts. When I was confronted with this years ago, I went to mibuso.com (ofcourse) and found a good solution from Stijn Bossuyt, who used the code from Igor Pchelnikov: http://mibuso.com/downloads/interleaved-2-of-5-barcode-creator

Based upon that information I then created the report.

The source code is available here:

So I thought, why not share this?

Thanks to:

  • Stijn Bossuyt:
    Blog: http://mibuso.com/blogs/lyot
  • Igor Pchelnikov:
    For the following post on Mibuso: http://mibuso.com/dlinfo.asp?FileID=1185
  • For the details about barcoding:
    http://www.barcodeisland.com
  • Description of the BMP file format:
    http://en.wikipedia.org/wiki/BMP_file_format
PS:

There’s however a much better way to achieve the same goal. You can use a free web service to generate your barcodes, and .NET interop to manage it. Please have a look here:


Discover more from think about IT

Subscribe to get the latest posts sent to your email.

5 Thoughts on “How Do I: Print Barcodes in RDLC?

  1. Pingback: How Do I: Print Barcodes in RDLC? - Microsoft Dynamics NAV Community

  2. Pingback: How Do I: Print Barcodes in RDLC? - think about IT - Dynamics User Group

  3. Pingback: How Do I: Print Barcodes in RDLC? | Pardaan.com

  4. I prefer this method better than the web service, as the web service can be down at any moment, or the customer might have NAV behind a firewall.

    Let me add a reference to this link, in case you need to put barcodes in report headers, you will to combine it with “getdata” and “setdata” report embeded functions:

    http://www.seccount.com/en/developers-blog/nav-development/pass-picture-using-setdata

  5. Thanks! It works like a charm and the code is easy to understand 🙂

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Post Navigation