Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Opening Cashdrawer command
Message
De
16/05/2009 20:27:33
 
 
À
16/05/2009 19:22:41
Luis Santos
Biglevel-Soluções Informáticas, Lda
Portugal
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Vista
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Desktop
Divers
Thread ID:
01400258
Message ID:
01400263
Vues:
99
>Hello comunity
>
>I need to know how to build a simple PRG to opening my cashdrawer that was connect to my printer Epson Tm-T88II .
>Also, if someone could give me an example using ports COM1 or LPT1.
>The ideia is create a shortcut on windows desktop an clicking on them, the PRG send the correct ASCII code to opening my cashdrawer .
>
>If is only possible on my VFP application calling the PRG or FXP, that´s not represent any problem, because i can use any combination of keyboard , ex : CTRL+F12 to call them.
>
>I search on the WEB but i couldn´t find any example.
>
>Many Thanks
>Luis Santos

Hi Luis,

This works for me. You wouls have to substitute the name of YOUR receipt printer for oAPP.receipt printer. My OS is XP PRO so that may also make a difference>
LOCAL lcOldPrinter

lcOldPrinter=SET('PRINTER',2)

TRY
     SET PRINTER TO NAME (oAPP.receiptprinter)
     SET PRINTER off
     ??? Chr(27)+CHR(112)+chr(0)+chr(64)+chr(240)
     SET PRINTER on
     SET PRINTER OFF
     SET PRINTER TO NAME (lcOLDPrinter)
			
CATCH
FINALLY
ENDTRY	
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform