Solved

How do I determine if a printer will print to PDF format

Posted on 2004-09-06
6
245 Views
Last Modified: 2010-04-17
I need to be able to check all installed printersand or drivers programatically on a pc and determine if they can produce a PDF file, So that I am able to give the choice of which one to choose.
0
Comment
Question by:SCSUSERLTD
6 Comments
 

Expert Comment

by:sls80
Comment Utility
What language are you programming in?

Also, generally you would create a PDF file and then send it as a print job to a selected printer. Are you using non-typical printers that would not be able to print PDFs?
0
 

Author Comment

by:SCSUSERLTD
Comment Utility
Sorry should have mentioned language.
I am programming with VB6.

There are various printers/drivers that can be installed to produce a PDF file, in addition to Adobe Distiller

I am writing a DLL that will allow a user to add an email attachment, If a PDF writer or writers are installled then the user should be shown the list and allow them to select a PDF printer. The resulting PDF file would then be attached to the email and sent. The users  printer selection would then be used for any future email attachments



0
 
LVL 19

Assisted Solution

by:akoster
akoster earned 150 total points
Comment Utility
I don't know any property which states wether a printer can generate pdf output or not.

Maybe you could manually make a list of all printers that allow pdf creation and check for (parts of) their name ?
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Accepted Solution

by:
sls80 earned 350 total points
Comment Utility
There is a zip file on this site that contains an example of how to enumerate through printer drivers for various operating systems:
http://www.vbdiamond.com/ViewSource.aspx?Type=VB&ID=114702

Direct link to zip download:
http://www.vbdiamond.com/DownloadFile.aspx?Type=VB&ID=26163

This site also provides an example of accessing printer driver properties that may be of some use:
http://www.devx.com/vb2themax/Tip/19573

I think the above suggestion about detecting printer drivers allowing PDF creation is a good one, as I'm not sure if that is possible either. It would need to be an available property of the printer driver in VB6 for you to be able to pick it up programatically, and I don't think that is the case. A naming convention for printer drivers may be the way to go, or you could automatically create a printer driver when your code executes if you know that the other components are available.
0
 

Author Comment

by:SCSUSERLTD
Comment Utility
Thanks for the suggestions I will try them.
Will come back with progress
0
 
LVL 3

Expert Comment

by:santosh26676
Comment Utility
MAy be use the Printers object and run thru the properties. It will have a property that will indiacte the drivers used by each printer. Incase you find "PDF" in the driver you know it is a PDF Driver.

Hope this helps.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
commonTwo  challenge 63 98
strCount chalenge 3 50
word0 challenge 3 55
LINUX, CPANEL & WHM 5 16
Here we come across an interesting topic of coding guidelines while designing automation test scripts. The scope of this article will not be limited to QTP but to an overall extent of using VB Scripting for automation projects. Introduction Now…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

762 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

6 Experts available now in Live!

Get 1:1 Help Now