This page has been designed specifically for the printed screen. It may look different than the page you were viewing on the web.
Please recycle it when you're done reading.

The URI for this page is { http://blog.scrobbld.com }

Using mail merge for packing slips Posted on December 18th

gdalogo70 We quite often field questions regarding including receipts, invoices or packing slips with your deliveries, to give that more professional touch. We don’t support the functionality directly in Scrobbld, but fortunately it’s not too difficult to achieve with mail merge in MS Word (probably also achievable with OpenOffice or similar).

The concept is a bit similar to our email notifiers where you insert placeholders into your document, and then connect up to a CSV file, which you can get from your Scrobbld data export.

I would like to extend my thanks to Andres from the Green Day Authority for very kindly allowing me to add his packing slip to this post, as a template which anyone else can alter and use. If you do decide to use Andres’ template, please share any results with other members by either writing to me or adding a comment here.

To use the attached template, I will quote directly from Andres’ usage instructions below, then add a few additional comments;

We just take the csv export from Scrobbld, set it as the Data Source in Word, and everything else plugs right in appropriately.

The only short-coming of this exact invoice is that I don’t have if-statements in there appropriately surrounding each item to check if that item exists. So if the export only has at most 5 items in a single order, I have to delete rows 6 and 7 from the invoice before creating the mail merge or it’ll throw an error. But, hasn’t caused too many issues for us.

Now, regarding connecting the data source in Word (2010 – I imagine 2007 as well) to the Scrobbld CSV file, you can refer to this link http://office.microsoft.com/en-us/word-help/about-mail-merge-data-sources-HP003082024.aspx.

Andres also mentions about adding if, then & else blocks. For the non-programmers among our users, this just means that if a particular text field, for example, address_country_code matches ‘UK’, then you display a different shipping time to if it matches ‘US’ (for example). This is easily achievable in mail merge documents; just refer to http://answers.microsoft.com/en-us/office/forum/office_2010-word/mail-merge-rules-using-if-then-else-for-a-date/abb0fb23-4cea-4990-9de6-6e34cbb7a6bf. Looping through multiple items I believe is a slightly more difficult proposition, but I think the solution here is a good and simple one, as items 1 through 7 are listed, just in case your customer decided to buy 7 different items from you. If they didn’t buy that many, it doesn’t matter, the fields will just be blank (especially if you nest them in the if-then-else blocks).

Please enjoy the Greendayauthority.com invoice!

Trackback URL
Leave your own comments about this post: