Wrox Home  
Search P2P Archive for: Go

  Return to Index  

pro_vb thread: controlling printer


Message #1 by "Anson Wun" <ansonwun@l...> on Wed, 22 May 2002 15:44:06
I posted some code pretty close to what you want to do about a week ago -
check  out
(might wrap)
http://p2p.wrox.com/archive/pro_vb/2002-05/16.asp

1. If you're talking about the windows generated printer error dialog - I
haven't investigated that - no clue at this point.
2. Query the printer before printing is no big deal - if there aren't any
print jobs, I was never able to get any useful infomation from my queries,
other that the printer was there - so if you trying to test if the printer
is offline, not turned-on, etc... w/o a print job - good luck - if you
figure out a way to get decent information please send me some the code your
using.
3. The code I sent is to the prior post should do what you want, you can
build on that.

hth
Jack

----- Original Message -----
From: "Anson Wun" <ansonwun@l...>
To: "professional vb" <pro_vb@p...>
Sent: Wednesday, May 22, 2002 3:44 PM
Subject: [pro_vb] controlling printer


> Hi. Is there any way to query and control the print spool using VB6? More
> specifically, I want to achieve either one of the followings:
> 1. Disable to Printer dialog box - that is, no matter what printer error
> is, don't prompt the user about it, or
> 2. before printing something, I want to query the printer first. If the
> printer is out of paper, then don't print and don't prompt the user, or
> 3. once a print job is sent and if the printer is out of paper, delete
> that print job (or all previous jobs) and don't prompt the user
>
> Your ideas are much appreciatd.. Thanks a mil!
>
> Cheers,
> AW
>

  Return to Index