Graham Mayor

... helping to ease the lives of Microsoft Word users.

Many people access the material from this web site daily. Most just take what they want and run. That's OK, provided they are not selling on the material as their own; however if your productivity gains from the material you have used, a donation from the money you have saved would help to ensure the continued availability of this resource. Click the appropriate button above to access PayPal.

Insert BarCode add-in for Word 2013 and later

Thanks to a little know pair of fields, introduced in Word version 2013 and retained for later versions, it is possible to insert bar codes in documents. These fields DISPLAYBARCODE and MERGEBARCODE are documented on Microsoft's web site, but the syntax is a tad tortuous and so I have produced the add-in featured here to complete that syntax based on a few selected pieces of information.

The two fields are, as their names suggest, available to insert a bar code and to merge a barcode. To cater for the latter, the add-in's merge options are only available when the active document is a mailmerge document.

The add-in provides the ability to insert the three most popular types of bar code. They are the CODE128 bar code, which is perhaps the most widely used and versatile, the CODE39 which has a more limited use and the two dimensional QR which can be read using a phone app.

I don't propose documenting the codes themselves as this is well covered on line. The only issue of relevance is that the CODE39 employs a start and stop code signified by a an asterisk at each end of the code. This is inserted by the add-in so any attempt to add the asterisk to the text to be coded will result in an error message. Similarly CODE39 has a limited character set compatibility so only permitted characters are allowed to be entered.

From left to right below we have CODE128, CODE39 and QR respectively.

Using the add-in

Mail Merge Options

The merge options only appear when the active document is a mail merge document attached and may only be selected when that document is attached to a merge data source.

Select the field that contains the barcode data.

In the case of CODE39, do not include the start and stop codes '*' in the data source as these are added by the process, and if present in the data will produce an error message and not a bar code when merged.

   Click here to download the add-in

 

 

 Insert Bar Code

This page features a simple add-in to help users round the syntax for inserting the DISPLAYBARCODE and MERGEBARCODE fields introduced in Word 2013.