Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sending hex printer commands from a program
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00666878
Message ID:
00666924
Vues:
22
>>Hi all,
>>
>>I need to send hexidecimal commands to an Epson LQ-570e dotmatrix printer in order to print a barcode on a document. Just trying to send the commands with
?? 0x1B 0x28 0x42 && command to print a barcode
gives a syntax error. Do I need to set up ASCII variables and use
TRANSFORM(variable, format)
to get VFP to send hex codes? Will just assigning a hex value to a variable
local lnPrintBarCodeCmd
>>lnPrintBarCodeCmd = '0x1B 0x28 0x42'
>>??  lnPrintBarCodeCmd
give me what I need?
>>
>>Hacking away....TIA
>
>Try
??? CHR(0x1B) + CHR(0x28) + CHR(0x42)
Remember, that it wouldn't work if you print thru Windows driver because it will discard all none printable characters.

The whole document is formatted using
?? "string" +var+ "string" at position, font, style
running under VFP6, Win98, networked printer. I thought that since I was sending line commands to the printer, that sending the appropriate printer commands would work as well. I'll find out later. Thanks.
Opportunity is missed by most people beacuse it is dressed in overalls, and looks like work --- Thomas Edison
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform