Solved

Query printer driver

Posted on 1997-04-13
4
381 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

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
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…

713 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