Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - Problem with margins when printing
  FAQ FAQ  Forum Search   Register Register  Login Login

Problem with margins when printing

 Post Reply Post Reply
Author
Message
xianchian View Drop Down
Beginner
Beginner


Joined: 12 Sep 11
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote xianchian Quote  Post ReplyReply Direct Link To This Post Topic: Problem with margins when printing
    Posted: 12 Sep 11 at 5:51PM
Hello,

I implemented a service to print documents using QuickPDF Library.
But I'm facing 2 problems right now

1/ I can't print on a physical printer in grayscale mode
2/ Some documents with custom margins, aren't printed correctly. The outfitting margins aren't printed.

So to fix the 2nd problem i tried to set the Paper length and Paper Width of the PdfLibrary. But i can't find the best value to make the document fit in the printableArea.
Does anyone have an idea on how to deal with this issue please?

Thanks!!
Back to Top
xianchian View Drop Down
Beginner
Beginner


Joined: 12 Sep 11
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote xianchian Quote  Post ReplyReply Direct Link To This Post Posted: 12 Sep 11 at 5:52PM
For the first point, i posted on an old post talking about it too.
Here is a link to the post
http://www.quickpdf.org/forum/how-to-print-color-pdf-in-grayscale_topic1322.html
Back to Top
AndrewC View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 08 Dec 10
Location: Geelong, Aust
Status: Offline
Points: 841
Post Options Post Options   Thanks (0) Thanks(0)   Quote AndrewC Quote  Post ReplyReply Direct Link To This Post Posted: 13 Sep 11 at 9:49AM

1. One option could be to create a 2nd printer with the print defaults set to your required custom settings as per this comment I found via google - 

http://nicholas.piasecki.name/blog/2008/11/programmatically-selecting-complex-printer-options-in-c-shar/

"What I did was create an entirely new printer with a uniquely indicative name on the print server that points to the same IP address. (I’m using a windows print server, so this might not work if you have a different setup) For this second printer, I clicked Properties>Advanced Tab>Printing Defaults Button, then I configured all of my printing options (default drawer, paper type, stapling options) and saved it. Theoretically anybody who connects to that printer now gets those options as the default. Then in my code, iterate through all connected printers looking for an indicative string in the name and print the job to that printer. I search for a string instead of hardcoding it because I have 2 departments doing the same task to two seperate printers, so all I need to worry about is getting each profile connected to the right printer and the app just works after that."

2. What exactly do you mean by "outfitting margins" - do you mean the cutting or trim marks ?  Do these marks show in Acrobat or other programs.  The CropBox and MediaBox can affect the printing of these marks.  Do you have a sample PDF we can look at ?

Have you looked at the QP.PrintOptions() function that has AutoRotateCentre, FitToPaper  options.

Andrew.
Back to Top
xianchian View Drop Down
Beginner
Beginner


Joined: 12 Sep 11
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote xianchian Quote  Post ReplyReply Direct Link To This Post Posted: 14 Sep 11 at 11:07AM
Hello,

2. By outfitting margins i mean cutting. When i print the document with Acrobat, it's going well.
I didn't work with the FitToPaper option, and i'm going to test it to see if it's better.
Once my test will be done, i'll link you to the document printing bad.

Thanks for the answer, i'll look at the link you provided for the 1st point.
Back to Top
xianchian View Drop Down
Beginner
Beginner


Joined: 12 Sep 11
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote xianchian Quote  Post ReplyReply Direct Link To This Post Posted: 14 Sep 11 at 11:38AM
2. The FitToPaper did the job.

Now i'm gonna try the color option.

Thanks much.
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store