Re: Printer commands
- From: "Phil Benson" <philbenson@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 30 Aug 2005 16:23:06 -0400
Liz,
I tried using the code you suggested (and filled in all the other numbers in
the string) and I read the Help file, but it doesn't do anything. In Help I
see how to open a text file and write to it, but I don't see anything
referencing opening a printer port by naming the port (it doesn't say it
won't, either). I have checked to ensure that the printer is really
attached to LPT1, and that it receives other commands (like printing a
report). The Help file says writeString sends characters to a text file,
but I'm presuming that if LPT1 is opened by the ts.open() event, then it
should be writing the string to the port. I tried it with writeLine also,
with the same result.
Is there something I can send to the printer in the same way which will
print out (rather than open the cash drawer) so that I can see if anything
actually gets to the printer? Or am I missing the whole thing somehow?
Phil
"Liz McGuire" <liz@xxxxxxxxxxxxxxxxxxxx> wrote in message
news:4313D089.6ED98503@xxxxxxxxxxxxxxxxxxxxxxx
> Phil,
>
> Open a textStream variable on the LPT port and "writeString()" the
> commands:
>
> ts.open("LPT1","nw")
> ts.writeString(chr(27),chr(112)...)
>
> See TextStream in ObjectPAL help for details on how to use it.
>
> Liz
>
>
> MouseHart wrote:
>>
>> I have a sort of an odd problem. I wrote a small POS system in Paradox
>> 10
>> for an Episcopal church store (much like the Salvation Army), and all it
>> needs to do after a sale (or after "No Sale" is entered") is print a
>> receipt
>> and open a cash drawer. I bought both the cash drawer and the receipt
>> printer from POSGuys.com, and the brand name on them is POSx. The
>> printer
>> is a parallel port printer which emulates an Epson TM-U200 receipt
>> printer,
>> and the cash drawer plugs into it. When the proper command is sent to
>> the
>> printer, it prints a receipt and opens the cash drawer. I called the
>> manufacturer and tested that it worked by following their instructions
>> which
>> were: open Wordpad, find a font named "control" (they said sometimes you
>> have to open Wordpad twice to be able to see this font; go figure), type
>> the
>> letter "A", and send it to the printer. That successfully opens the cash
>> drawer. I have no clue why this works and neither did the tech.
>>
>> They also gave me two code strings of numeric commands either one of
>> which,
>> when sent to the printer, is supposed to open the cash drawer. They said
>> to
>> insert one of them after all the other printer commands (like the report
>> print command, I presume). The code strings are 27,112,48,25,250 or
>> 27,112,0,25,250. I have absolutely no idea what to do with them or where
>> to
>> put them in order to get the drawer to open, and neither does the
>> manufacturer (they've never dealt with Paradox). I can get the register
>> tape to print just fine by sending a Paradox report to it, but can't
>> open
>> the drawer. My only other choice is to never give the customer any
>> change,
>> but that sounds harsh.
>>
>> I'd appreciate any help I can get. Thanks.
>>
>> Phil Benson
>> CrossFire Software, Inc.
.
- Follow-Ups:
- Re: Printer commands
- From: Tony McGuire
- Re: Printer commands
- References:
- Printer commands
- From: MouseHart
- Re: Printer commands
- From: Liz McGuire
- Printer commands
- Prev by Date: Re: PDOXUSER.NET
- Next by Date: Re: Printer commands
- Previous by thread: Re: Printer commands
- Next by thread: Re: Printer commands
- Index(es):
Relevant Pages
|