cancel
Showing results for 
Search instead for 
Did you mean: 

PCL command sap-script

Former Member
0 Kudos

Hi,

What is MICR code and PCL command in sap-script

and what is the meaning of this piece of code

/: IF &DEVICE_TYPE& = 'ZA012011'

* <32>

/* & % S T H P A S S W O R D $ & % S M D

/: HEX TYPE PCL

= 262553544850415353574F5244242625534D44

/: ENDHEX

= O&REGUD-CHECT+3(10)&O

/: HEX TYPE PCL

= 24262553545124

/: ENDHEX

/: ENDIF

Points assured.

Regards,

Maahi

Accepted Solutions (1)

Accepted Solutions (1)

amit_khare
Active Contributor
0 Kudos

PCL commands are the Printer comands given by 3rd party system and used in Scripts to print on some particular printer.

e.g. ZPL commands for ZEBRA printers.

Regards,

Amit

Reward all helpful replies.

Answers (2)

Answers (2)

Former Member
0 Kudos

not answered

Former Member
0 Kudos

Hi Maahi,

Did you understand what the statement "HEX TYPE PCL" means?

As far as MICR code is concerned, can you tell me the context where you came across this.

Regards

Indrajit

Former Member
0 Kudos

Hi Maahi,

PCL stands for HP Printer Control Language.

The command HEX, ENDHEX is used to send printer commands in a printer language directly to a printer that supports that language. SAPscript does not interpret the data enclosed by the HEX and ENDHEX command pair, but inserts it unchanged into the output stream. This technique allows objects with a pixel-oriented format (for example, graphics) to be printed as part of a SAPscript text. The HEX and ENDHEX command pair enclose the printer commands and data as hexadecimal text, so that the printer formatting routines interpret each successive pair of characters as a single hexadecimal value in the range of 0 to 255. The characters 0 to 9 and A to F for representing the values 10 to 15 are valid hexadecimal characters. The text may also include comment lines (these begin with /* in the format column), which will not be interpreted as hexadecimal data but are simply passed over by the formatting routines.

<u><b>Syntax:</b></u>

<b>/: HEX [TYPE printer_language]</b>.

The HEX command denotes the start of the hexadecimal data. Subsequent text lines are interpreted as described above. If the TYPE parameter is present, the data will be sent to the printer only if the printer understands the specified printer language. The following printer languages are currently supported: POST (Postscript), PRES (Kyocera Prescribe) and PCL (HP Printer Control Language).

<b>/: HEX [TYPE printer_language] [XPOS x_position] [YPOS y_position]</b>

The output cursor is set to the absolute position indicated by the specified X and Y position parameters before the hexadecimal data is printed. If either the X or the Y position is not specified, then 0 will be assumed for this parameter.

<b>/: HEX [TYPE printer_language] [HEIGHT height] [LEFT left_indentation]</b>

The HEIGHT parameter determines the amount of space to be reserved on the page for the output of the hexadecimal data. Any text following the ENDHEX command will be printed below this point. If the LEFT parameter is also specified, then the output of the hexadecimal data will is indented from the left margin by the specified amount.

/: HEX TYPE PCL HEIGHT '7.5' CM LEFT '2.25' CM

/* Creator: report ZQVNTE30 date 19940705 time 125129 user SAPSCRIPT

/= 1B2A7230461B2A743735521B2A7231411B2A62304D1B2A62343057FFFFFFFFFFFF

/= FF1B2A62343057FFFFFFFFFFFFC0007D00DFC0F7D0000000000000000000000017

/: ENDHEX

This data is printed only by an HP PCL printer (fro example, HP LaserJet). 7.5 cm of space is allocated on the page for the output of the data and the output cursor is indented 2.25 cm to the right of the form window edge.

You can use the RSTXLDMC program to upload correctly formatted pixel data to the R/3 system and to prepare it as a HEX-ENDHEX control command. This can then be saved as normal SAPscript text.

Award points if found useful.

Regards

Indrajit