|
-
April 2nd, 1999, 05:22 PM
#1
URGENT : Direct printing...?! How ?
Hello...!
I have a big (for me) problem :
I want to print _directly_ to a specified printer. Well, the user have several printers installed on his system and i want to print a bill on one specified printer without showing the PrintDialog.
I have already tried to realize it with the 'SelectPrinter'-Function, the DEVMODE- and DEVNAMES-Structure, but unfortunately it did not work so far...
(
I would be very glad if someone could give me a tip or some sample code...
...thanx in advance very much, Torsten Jochem. ~ )
-
April 2nd, 1999, 06:04 PM
#2
Re: URGENT : Direct printing...?! How ?
I can give you a hint for direct printing to the default printer
You simply have to to modify the m_bDirect - member in the pInfo struct.
Do this in your override of the OnPreparePrinting
hope that helps
thomas
-
April 2nd, 1999, 06:11 PM
#3
Re: URGENT : Direct printing...?! How ?
Thanx Thomas... ~ )
..unfortunately, i have 2 printers on the system. A small bill-printer (thermo) and a (normal DINA4) printer for larger lists...
...the application shall print different reports (bills and lists) to the 'bill-printer' or the 'list-printer' without showing this Print-Dialog.
Unfortunately only ONE printer can be the default printer... (
But thanx a lot ! Bye Torsten.
-
April 4th, 1999, 04:15 AM
#4
Re: URGENT : Direct printing...?! How ?
Hi....
* * * * * Happy Easter. * * * * *
first open the printer port (LPT1/LPT2) whichever you want using CreateFile().
then using WrieFile() function you can send data to the specified Printer.
Hope this is enough for you.
bye & good luck.
Rajan K
Regards...
Rajan K
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|