Quantcast
Channel: Microsoft Dynamics NAV
Viewing all articles
Browse latest Browse all 64865

Blog Post: Printing label sheets through RDLC

$
0
0

Today, I needed to create a label sheet to print bar codes for a client implementation. So I thought I could share it with all of you. I think that some of you might already know how to do this, but anyway here it is.
First I made my data set which is pretty straightforward:

Report Dataset Designer

Add an Item with the No. and Description, next add the Cross Reference of type Bar Code which is not discontinued.

As for the layout of the sheet, I didn’t have the exact layout yet, so I looked on the internet for a typical label sheet, just to know the dimensions, and started from there. Here is what I used as an example.
Sample Label Sheet

My next step was to figure out how to set this up in our RDLC Designer. When we look at the Report Properties this is what we see:

Report Properties Page Setup

We can basically set the page size and margins, but nothing else. So I started there. My example said it was A4, so I set that. I didn’t notice a left or right margin in the example, so I set them to 0, I left a little top and bottom margin.

Our first setup look good, but how do I get multiple labels on a sheet. these are basically columns, but I do not wish to add a table with columns, because that would mean I need to add the “layout” multiple times. When we look at the properties list of the Report, this is what I found:

Report Properties List

A function called columns! with the option to set the spacing between. I changed Columns to 3 and set no spacing, here is what the Design now looked like:

Design Look

Now I could start by adding a list linked to the dataset, and add my fields. Before that, I also set the body size to 70mm wide and 36mm height.

As to actually print a bar code, all you need to do is set the TextBox font to a bar code font, and also install this at the customer side. Here is my end result:

Bar Code Font Properties

Final Design

After saving and running the report, here is the actual result, the output:

Result

So, as you can see, it really wasn’t that hard. When the label needs to be changed, I only need to change it 1 time. When I get the actual sheet size and label size, I need to change my page setup and the body size and I’m set.

I hope this helps you finding the properties whenever you’ll need to make a label sheet or something similar.


Viewing all articles
Browse latest Browse all 64865

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>