Follow the instructions listed below to print barcodes in a Smart Form:
(1) Start transaction SMARTFORMS.
(2) Copy the style "SYSTEM" to a local one "Z_BARCODE", save and then activate it.
(3) Right click "Character Formats" and choose "Create Node".
(4) Enter a name and a brief description into "Character Format" and "Description" fields respectively, choose a system barcode (e.g. ZC128) from the list, save and then activate it.
(5) Create a new form.
(6) Click "Form Attributes" and select "Output Options", choose Z_BARCODE as style.
(7) Insert a string or SAPScript variable into the form and highlight it, select your character format.
(8) Save and then activate it.