Solved

Setting Paperbin when printing to PDF printing software programs

Posted on 2009-05-04
4
635 Views
Last Modified: 2012-05-06
Hello,
My app works fine printing.... I have switched to the MS VbPrn.DLL for printing and still works well... but for some "PDF Printer" outputs... I'm getting an error setting PaperBin....  I have some default code that grabs all the values from the Print Dialog and copies them to the Printer.... PaperBin is an issue....

In this case it is set to '15' when it is copied to the Printer.PaperBin and this throws an "invalid value error".

How do we know what values are valid?

I have an if statement on there in case it's not defined at all... In this case it is set but the PDF Creator does not like it. Same with desktop PDF.

ANy ideas?

-Tim
0
Comment
Question by:torrid333
  • 3
4 Comments
 
LVL 20

Accepted Solution

by:
thehagman earned 500 total points
ID: 24294995
Hm, my printer dialog of PDF creator shows no different paper bins - you can rather palce arbitrary paper sizes in the "one" bin ...
0
 

Author Comment

by:torrid333
ID: 24295055
Right maybe that's the issue... but how do you tell the printer to ignore the paper bin?

Somehow by default there is a prnDialog value of 15... and my if code sees a value and tries to assign it...

Is there an if statement that I could use to check to see if that printer propert "exists" at all?  if so I could use that as the criteria as to whether to set it???

Having code that breaks on some printers and not others is going to be really annoying....

0
 

Author Comment

by:torrid333
ID: 24337777
The solution was to get code to check for number of paperbins... if that is ZERO then there are no paperbins and it's a PDF printer.... There is code on the internet on MSDN to check for number of paperbins.
If the PDF printer would just let number of paperbins default to 1 this would not have been an issue.. I have found that some of them worked fine like PDF XChange so they must have done that. Whereas PDF Creator caused an error so did not....

Hope this helps someone.
0
 

Author Closing Comment

by:torrid333
ID: 31577529
I'm awarding points even though I had to figure it out myself...
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

How to remove superseded packages in windows w60 or w61 installation media (.wim) or online system to prevent unnecessary space. w60 means Windows Vista or Windows Server 2008. w61 means Windows 7 or Windows Server 2008 R2. There are various …
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

706 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

19 Experts available now in Live!

Get 1:1 Help Now