I decided not to use this type of system to open the drawer because I want to be able to open the drawer independent of the printer.
I dropped the MsCommLib.MsComm.1 onto a form with code as below With Thisform.oComm .CommPort=tillport .Settings=tillspeed .RThreshold=1 .Portopen=.T. If Not .Portopen() =Messagebox("Invalid Port") Return .F. Endif .Output = "UUUUU" + Chr(13) && Dialing the number .Portopen = .F. Keyboard "Ctrl Enter" Endwith Now you can open the till with a "hidden" hot key or a command button on your form, or as part of closing the sale. On Thu, Feb 18, 2010 at 8:58 AM, Jeff Johnson <j...@san-dc.com> wrote: > Kent: I have a POS application that uses an Epson TMU220 receipt > printer and a cash drawer. The printer sends a command to the cash > drawer to open it. Here is my program to open the cash drawer: > > PROCEDURE rswdrawer > > > > lcdrawercommand = CHR(27) + CHR(112) + CHR(48) + CHR(55) + CHR(121) > > > > =pr_on() > > > > ??? lcdrawercommand > > > Where =pr_on() sets the printer to the receipt printer. > > The specifications of the drawer you are using will tell you what the > commands are. > > HTH > > Jeff > > Jeff Johnson > j...@san-dc.com > SanDC, Inc. > 623-582-0323 > Fax 623-869-0675 > > > > Kent Belan wrote: > > Hello, > > I have been asked to add a cash drawer to my VFP9 app so that when the > > payment is entered it will open the cash drawer. > > > > Someone must have done this already and knows the perfect cash drawer to > > purchase that will work with VFP9 ? > > > > Thanks, > > Kent > > > > [excessive quoting removed by server] _______________________________________________ Post Messages to: ProFox@leafe.com Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/367498c41002171251w17061727q6fd4c50c65ef4...@mail.gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.