Connecting with tools such as cash drawer
Posted by: fredometro on
Jan 6th, 2004 |
Filed under: MS-Access
Quertion: I try to develop Point of Sales program by access. I have trouble in connecting the program with the tools such as cash drawer. My question is that if on click event I want to drawer to activate (Open) How do I?
Drawer connect to PC using serial port
Thanks
Fredix gave this response on 4/3/2002:
Hi!
You have two choices: The simplest is to use .bat files that sends the appropriate commands. You call the .bat with the shell() function.
More sophistcated and better method is to use the MsComm control. It contains all the features for controlling the serial ports.
Look at this page for a good example:
http://www.freevbcode.com/ShowCode.Asp?ID=2236
Regards.
Fredix gave this response on 4/3/2002:
Here is an example. There is only a three line .bat file, called print.bat:
mode com1:19200,n,8,1
type c:\\caisse\\pfile > com1
exit
When I need to send some characters to the peripherals, I build the c:\caisse\pfile like this:
Open “c:\\caisse\\pfile” For Output As 1
Print #1, Chr(27) & “=” & Chr(1);
Print #1, Chr(27) & “p” & Chr(0) & Chr(20) & Chr(20);
Close 1
Finally call the print.bat, which sends the file to Com1
Shell(”c:\\caisse\\print.bat”, 7)
This method works quite well and is easy to implement. However, the problem is that the DOS window remains on the screen. To avoid this, the first time the window is here, right-click the top of the window, choose properties and check the box ‘close on exit’.
I would prefer using MSComm control, but the app was in Access 2.0, so I had no choice. The advantage with MSComm is that you can check if the peripherals are ready. This is important as this program must run the whole day long, and there is a client in front of the user.
Good luck with your program


December 12th, 2009 at 5:57 am
Sex Crazed Mommas
December 12th, 2009 at 5:58 am
Rope Rookie
December 12th, 2009 at 5:59 am
Feet On Streets
December 12th, 2009 at 6:00 am
Mai Ly
December 12th, 2009 at 6:01 am
Girls Of Porn
December 12th, 2009 at 6:03 am
Anal Outlaws
December 12th, 2009 at 6:04 am
Virgin Confession
December 12th, 2009 at 6:05 am
Masha Star
December 12th, 2009 at 6:06 am
Naughty Chrissy
December 12th, 2009 at 6:07 am
Goth Tease
December 12th, 2009 at 6:08 am
3 way sex Parties
December 12th, 2009 at 6:09 am
Erotic Eve
December 12th, 2009 at 6:10 am
Natalie Sins
December 12th, 2009 at 6:11 am
Dolly Morgan
December 12th, 2009 at 6:12 am
XXX Mina
December 12th, 2009 at 6:13 am
Mature Lovers
Add A Comment
You must be logged in to post a comment.