If you are in a business where you need to send correspondence to your clients or affiliates, chances are, there are mailing labels being generated and printed at some point of the process. God forbid you to have to make them yourselves, right? Luckily software like Microsoft Word already provides some Mail Merge functionality to make these tasks easier. You can use data in your Excel and mail merge it with a Word document.
The problem, however, is if you have to create mailing labels from data uploaded to SharePoint. It’s not so simple to integrate the SharePoint data with Word mail merging capabilities, or export SharePoint information to a Word in the correct format, especially if you want to get information from multiple SharePoint lists.
And that’s where JungleDocs comes in as a simple way to do that. In this post, I will demonstrate how to configure JungleDocs for mail merge with multiple SharePoint list items. Once you configure JungleDocs, mail merging will be as simple as one-two-three! Quite literally, in fact: one – select SharePoint items, two – run JungleDocs from the ribbon, three – click on JungleDocs rule. You can even use the whole SharePoint list, view or simply export current SharePoint list view with filters.
Exporting SharePoint list data to a document using JungleDocs
Creating mailing labels in SharePoint is one of the simplest tasks to complete using JungleDocs. JungleDocs comes with few pre-configured rules, and once you install it and activate the site feature, you will find a report rule called “Export list to word”
By default, it will let you export selected, filtered or all items in the list to a word document. The table would have all of the columns that are in your current view. The default table is of no use for us in this situation and the first thing we need to do is to change the template.
Creating a mailing label template
Before we jump on to configuring, you need to figure out how your ready mailing labels need to look like. If you are already creating mailing labels – it is simple, you can use your template if you have one. If you don’t have a mailing label template but you know what the requirements are, you can easily create one.
I decided to use one of the mailing label templates given by Word. You can create a new document from the template, by choosing a label standard. To access those templates, open a word document, click Mailings in the ribbon and click Labels:
It will open label configuration and if you click on the preview of the label, you can choose one of the existing predefined formats:
After (and if) you find your required label configuration, click on and click “New Document” to get a new word file with your required settings. Save the file because it will be required later on.
Configuring JungleDocs to create mailing labels
Configuration is very simple. It involves some copy pasting and clicking the correct buttons. Clicking buttons in JungleDocs can seem a little complicated at first, but I will show you where everything is.
First, we need to enable custom template. To do that you have to click the downward arrow on JungleDocs rule and click “Edit Report rule”:
You will access the settings and you need to enable template management. So click “Enable template management”:
Now you have access to the template and sample document, open the sample document:
At this point we can either:
• Start editing the template and create it from scratch;
• Upload an already existing document and use it as mailing labels template.
Naturally, I would choose #2. To upload a document you need to click “Manage custom template” again and locate it:
Click ok to save the document and open it for editing. My selected label format looks like this:
I got lucky and my labels have an already visible outline so this makes things easier. If you seem to just have an empty file, press Crlt + A to select everything and add borders to your table. As it turns out, the whole mailing label template is simply a correctly sized table with right margins. We only need one cell for our configuration, so the first thing to do is deleting all rows except one. Select them and click Delete Rows.
Now comes JungleDocs bit. You need to select the whole table (which is now just one cell) and add a content control. You can find it under Developer tab in Word, and if you cannot see this tab, you can edit your ribbon and enable Developers tab. So select the whole table and click to add a Rich Text Content Control.
The result should look like in the picture below. Now you need to click Properties:
And enter “ReportItems” in the Tag field. This will let JungleDocs know what to do with this file:
You should still have JungleDocs sample document from before open. If not, go to JungleDocs rule settings and open it again. It contains all of the content controls for columns in your list. So we need to copy those content controls from our sample document, into the mailing label template, placing them where they need to be:
You can keep or remove borders if you wish, but otherwise, the configuration is done! Now we can test our generated mailing labels. I have a test list with some random contact information. So I can select the list items I need the mailing labels for, click JungleDocs button in the ribbon, click on the rule that I configured, and voila – we have a document of mailing labels for the SharePoint list items that we selected:
If you make the document contain columns, the labels will be listed in multiple columns, it all depends on the template configuration and possibilities are endless!