Main Board > Language
Best use of 'ES' mnemonic
(1/1)
James Zukowski:
There are several methods within PxPlus to generate an ESCape character: CHR(27), $1B$, esc variable, and 'ES' mnemonic. In most cases, the 'ES' mnemonic is (and should be) set to a value of $1B$.
However, certain printers may use a different "attention" character, e.g., Printronix typically uses $01$. Would this be a better use of the 'ES' mnemonic, since a $1B$ wouldn't necessarily do what one would expect?
Thoughts?
Mike King:
If you have a printer where the ESCAPE is other than $1B$ you can set the value of the 'ES' mnemonic in the device driver using the MNEMONIC directive.
For Example:
->open (1) "*memory*
->mnemonic (1) 'es'=$01$
->print (1) 'es'
->read record (1,ind=0) R$
->print hta(R$)
01
->
Changing the mnemonic will not change value of ESC however, only change what will output when you issue the 'ES' mnemonic to the device.
Navigation
[0] Message Index
Go to full version