Solved

Query printer driver

Posted on 1997-04-13
4
376 Views
Last Modified: 2006-11-17
Is it possible to query the printer driver for a status report druing long print jobs? I.E. # of pages printed, percent of current job?  If so, how?
0
Comment
Question by:smokin
4 Comments
 

Expert Comment

by:mehoss
ID: 1425357
I found this...Perhaps someone else could give an example...

Declare Function GetQueuedCompletionStatus Lib "kernel32" Alias "GetQueuedCompletionStatus" (ByVal CompletionPort As Long, lpNumberOfBytesTransferred As Long, lpCompletionKey As Long, lpOverlapped As Long, ByVal dwMilliseconds As Long) As Boolean

0
 

Author Comment

by:smokin
ID: 1425358
Adjusted points to 100
0
 
LVL 1

Accepted Solution

by:
advapp earned 100 total points
ID: 1425359
Yes, the Win32 API includes a GetJob function (usable from VB) that will return info on a job including these items and more:
   Total Pages
   Pages Printed
   Position
   Job Status
   Time Submitted
   User Name

However, if you've never worked with the API via VB you might need some help working this out.  If you accept this answer, I'd be willing to forward the necessary declarations and work with you on the code.

If you reject this answer, I'll assume you are not interested.

0
 
LVL 13

Expert Comment

by:Mirkwood
ID: 1425360
Bought This Question.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

896 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now