BarCodeURL

Generates the specified barcode using supplied information. This function does not support matrix (2-D) barcodes such as QR codes. Use this function a maximum of two times per each single message or landing page.

Syntax

BarCodeURL(1, 2, 3, 4, 5, 6, 7, 8, 9)

Function Properties

OrdinalTypeDescription
1stringRequiredValue to convert into a bar code
2stringRequiredType of bar code to create.
3numericRequiredWidth of bar code in pixels
4numericRequiredHeight of bar code in pixels
5stringChecksum value for bar code
6booleanDisplay bar code value from string as text. A value of 0 displays provided alt text. A value of 1 displays barcode value as text.
7stringAlt text to display if ordinal 6 contains a value of 1
8intRequiredOrientation of the bar code. A value of 0 displays barcode horizontally. A value of 90 rotates the barcode 90 degrees to the right. A value of 180 rotates the barcode 180 degrees. A value of 270 rotates the barcode 90 degrees to the left.
9booleanRequiredDisplay a transparent background for the barcode. A value of 0 does not display a transparent background. A value of 1 displays a transparent background.

Usage

Use this function to create these types of barcodes:

  • Codabar
  • Code11
  • Code128Auto
  • Code128A
  • Code128B
  • Code128C
  • Code39
  • Code39Ext
  • Code93
  • Code93Ext
  • Ean13
  • Ean8
  • Industr25
  • Interl25
  • Mat25
  • MSI
  • Postnet
  • Planet
  • Telepen
  • UPCa
  • UPCe
  • OneCode
  • DataMatrix
  • PDF417
  • PlainText

When the AMPscript below is placed in a content area, the email message receives the applicable bar code at the time of the send:

The AMPscript generates a bar code based on the value in Code39 format in the specified height and width. The AMPscript below displays the bar code with the listed alt text and rotated 90° to the right on a transparent background.

The AMPscript below displays the bar code with the string value as text and rotated 90° to the right on a transparent background. Note that the single quotes must be included when using the string value as text to prevent the function from returning an error.