Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to control programmatically the cash drawer?
Message
De
24/05/2005 00:20:39
 
 
À
21/05/2005 02:44:44
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows 2000
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
01016436
Message ID:
01016963
Vues:
8
Hi Holden

Here's some code I use:



cString = "UUUUU" && set to the string your printer needs eg. CGR(27)+chr(122)+CHR(0)_CHR(187)
cPort ="COM1:"
#Define ForReading 1
#Define ForWriting 2
oWshFile = CREATEOBJECT("Scripting.FileSystemObject")
If TYPE("oWshFile") #"O"
Return .F.
Endif
oCom = oWshFile.OpenTextFile(cport, ForWriting, .T.)
oCom.Write(cString)
oCom.Close
Release oCom
Release oWshFile
Return



>hi to all!
>
>i've been developing a POS System in a small retail store, and my problem is how to control programmatically the cash drawer? What i did for the meantime is to issue the DOS Shell about controlling the COM1. and it was successfully to open the cash drawer. but my second problem is how to detect if the cashier close drawer. What command normally is to use to capture the closing and opening of the cash drawer?.
>
>Thanks.
>
>Holden
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform