Solved

Open a cash drawer

Posted on 2006-10-28
3
1,323 Views
Last Modified: 2009-04-18
Hi, i have a Point of sale program that use a epson tmu200 printer. also it usea a cash drawer. the cash drawer is connected to the printer epson by a rj11 cable, the pirnter epson send a pulse and open the cash drawer. the printer epson is a paraler port

i use this code

Open "LPT1:" & strcommNumber For Output As #1
Print #1, Chr(27) + Chr(112) + Chr(0)
Close #1

if i use a serial , or a usb port printer, it don,t  open the cash drawer, the code is just for pararel port printers.

The question is some body know the code to open tha cash drawer with a usb port printer ?
0
Comment
Question by:cano63
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 1

Accepted Solution

by:
ogog earned 250 total points
ID: 17830019
i used to do this by using the "virtual" com ports. Scince the USB is always associated with a com: port.

try replacing LPT1: by COM1:, COM2... etc. try them all. In my PC i've got a total of 9 COM: ports!

here is what i used, it's working fine:

        Open "COM1:" For Output As #1
            Print #1, Chr$(27); Chr$(112); Chr$(0)
        Close #1

it's just like yours but i'm using the coms. try all numbers untill you get it right. (see in the harware panel how many you've got)

tell me how it goes.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question