Data from multiple fields may be included in a barcode by concatenating the fields in the Data section of the source formula. For example, two fields may be concatenated by specifying the fields with a + symbol between the, eg.
Data="+{Customer.Postal Code}+{Customer.Country}
which sets the data equal to the content on the Customer Postal Code field followed immediately by the content of the Customer Country field.
However, it is more likely that multiple fields need to be separated, typically by tabs or newlines. This may be achieved by concatenating characters between the fields using escape sequences; for example:
Data="+{Customer.Postal Code}}+"^p"+{Customer.Country}
inserts a new paragraph (carriage return + line feed) between the postal code data and the country data.
The following escape sequences are defined for the image creators:
^t Horizontal Tab
character
^r Carriage Return
character
^n Newline
character
^p new paragraph (Carriage Return
followed by Linefeed)
^s space character
So to produce a barcode containing a multi-line name and address the following formula could be used:
"http://localhost/dlbc2d/dlbc2d.aspx?CodeType=1&Xunit=16&Data="+
{Customer.Customer
Name}+"^p"+{@address1&2}+"^p"+
{@ciy/region}+"^p"+{Customer.Postal
Code}+"^p"+{Customer.Country}
Note that the escape character (^ in the above) may be modified using the Esc property.
Note also that many barcode scanners may be programmed to modify scanned characters – for example, by replacing a carriage return character by the carriage return – linefeed pair.
More: