Using barcodes in templates for invoices
Explore how to incorporate barcodes into your invoice templates using barcode merge fields, with support for up to five fields per template.
To have a barcode on your invoice, you need to use a barcode merge field in your template. Currently, Zuora supports up to five barcode merge fields per invoice template.
Use the following format for your barcode merge field:
{MERGEFIELD "Image:{BarCode field}, Value:[{Value}], CodeTextPosition:{CodeTextPosition}, ImageWidth:{image width in point}, ImageHeight: {image height in point}, DpiX:{dpi value horizontally}, DpiY:{dpi value vertically}" * MERGEFORMAT}
|
Parameter |
Possible values |
|---|---|
|
|
|
|
|
This can contain a string, a Customer Account or Invoice custom field, or a merge field from: |
|
|
This is an optional field that defines the text position of the barcode:
|
|
ImageWidth |
The width of the barcode, measured by points (1/72 inch). The value is an integer not greater than 3,200. |
|
ImageHeight |
The hight of the barcode, measured by points (1/72 inch). The value is an integer not greater than 3,200. |
|
DpiX |
The horizontal resolution of the barcode, measured by dots per inch (DPI). The value is an integer not greater than 500. |
|
DpiY |
The vertical resolution of the barcode, measured by dots per inch (DPI). The value is an integer not greater than 500. |
Example
The following example will return a barcode of the bill to contact's postal code:
{MERGEFIELD “Image:BarCode.Code128, Value:[{MERGEFIELD BillToContact.PostalCode \* MERGEFORMAT}]” \* MERGEFORMAT}
Example invoice template:
Returned example invoice: