Solved

Getting printer status - USB, network, etc...

Posted on 2003-11-20
1
412 Views
Last Modified: 2010-04-05
I can't seem to find a reliable way to get the status of a printer to know if it out of paper, powered off, etc...

I am looking for a solution that will work with USB, Network, paral. printers
0
Comment
Question by:moonrise
1 Comment
 
LVL 2

Accepted Solution

by:
Robn earned 250 total points
ID: 9790839
I haven't tried this but Delphi has a unit called WinSpool that has a number of implimented API's that can be called to retrieve printer information. Take a look at EnumPrinters. This method looks to have several types of records that can be passed in. The record TPrinterInfo2 has a Status member that you should be able to bitwise to determine if the PRINTER_STATUS_PAPER_OUT flag is set. You can look in the Printers unit to see how these API's are called.

Hope this helps,
Rob
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

Suggested Solutions

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

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

11 Experts available now in Live!

Get 1:1 Help Now