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 - A3 printing [SOLVED]
  FAQ FAQ  Forum Search   Register Register  Login Login

A3 printing [SOLVED]

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


Joined: 17 Nov 08
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote Eddy Quote  Post ReplyReply Direct Link To This Post Topic: A3 printing [SOLVED]
    Posted: 02 Mar 09 at 11:44AM
I've got an A3 printer and I produce A3 pdf files. I would like to print them on my printer...
When I do so, I obtain a... whtie page, with noting on !
My code is :

"
    sPrinterName = oPdf.NewCustomPrinter(sMyPrinter)

    oPdf.SetupCustomPrinter sPrinterName, 4, frmCustomImpr.iNbCopies   'Nb de copies
    oPdf.SetupCustomPrinter sPrinterName, 5, frmCustomImpr.iQuality    'Qualité
    oPdf.SetupCustomPrinter sPrinterName, 6, frmCustomImpr.iCoulor    'Couleur
    oPdf.SetupCustomPrinter sPrinterName, 7, frmCustomImpr.iRectoVerso 'Duplex
    oPdf.SetupCustomPrinter sPrinterName, 8, frmCustomImpr.iCollate    'Copies groupées ou non

    oPdf.PrintDocument sPrinterName, 1, 1, 2, oPdf.PrintOptions(1, 1, "PDF printing : mydoc.pdf")

"
Do I do something wrong ?
Thank you
Eddy


Edited by Eddy - 04 Mar 09 at 3:32AM
Back to Top
DELBEKE View Drop Down
Debenu Quick PDF Library Expert
Debenu Quick PDF Library Expert
Avatar

Joined: 31 Oct 05
Location: France
Status: Offline
Points: 151
Post Options Post Options   Thanks (0) Thanks(0)   Quote DELBEKE Quote  Post ReplyReply Direct Link To This Post Posted: 02 Mar 09 at 1:24PM

I don't know waht happens

Perhaps setting the PaperSize?

oPdf.SetupCustomPrinter sPrinterName, 4, 8 'Format A3
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 02 Mar 09 at 3:38PM
Hi Eddy!

I'm using the code below ...

Cheers, Ingo

    QP := TiSEDQuickPDF.Create;
    try
       QP.UnlockKey('mykey');
       QP.LoadFromFile(Edit1.text);

       If QP.Encrypted > 0 Then
          QP.Unencrypt;
       pc := QP.PageCount;
       prName     := QP.GetDefaultPrinterName();
       If ( Pos(' on ',prName) > 0 ) then
          prName := System.Copy(prName,1,Pos(' on ',prName)-1);
       prOptions  := QP.PrintOptions(2, 1, Edit1.Text);
       QP.PrintDocument(prName, 1, pc, prOptions);
    finally
       QP.Free;
    end;



Edited by Ingo - 02 Mar 09 at 3:41PM
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 02 Mar 09 at 3:43PM
Hi again!

In addition to Jean-Luc suggestion here something about SetupCustomPrinter:

SetupCustomPrinter
Description
Changes the properties of a custom printer created with the NewCustomPrinter  function.
Definition
Function SetupCustomPrinter(CustomPrinterName As String,
                            Setting  As Long,
                            NewValue  As Long) As Long

Parameters

CustomPrinterName
A custom printer name, as returned by the NewCustomPrinter  function.

Setting
1 = Paper size
2 = Paper length
3 = Paper width
4 = Copies
5 = Print quality
6 = Color
7 = Duplex
8 = Collate
9 = Default source (paper trays / bins)
10 = Media type
11 = Orientation

NewValue For paper size:
1 to 68, see DMPAPER_XXX values in Win32 API documentation for
DEVMODE data structure.
For paper height and width:
Size of paper in tenths of millimetres
For copies:
Number of copies
For print quality:
1 = high
2 = medium
3 = low
4 = draft
For color:
1 = monochrome
262
262270 Rendering
The Colden Group LLC
2 = color
For duplex:
1 = simplex
2 = vertical duplex
3 = horizontal duplex
For collate:
0 = no
1 = yes
For default source:
1 to 15, see DMBIN_XXX values in Win32 API documentation for DEVMODE
data structure.
256 and higher for custom bins / paper trays.
See the GetPrinterBins  function.
For media type:
1 = standard
2 = transparency
3 = glossy
256 and higher for device-specific media
For orientation:
1 = portrait
2 = landscape
Returns
0 The custom printer could not be found, or the Settings or NewValue parameters
were invalid.
1 The custom printer settings were changed successfully


Edited by Ingo - 02 Mar 09 at 3:45PM
Back to Top
Eddy View Drop Down
Beginner
Beginner


Joined: 17 Nov 08
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote Eddy Quote  Post ReplyReply Direct Link To This Post Posted: 03 Mar 09 at 3:27AM
Thanks you Ingo and Delbeke.
Unfortunatly, I've also tried out with the code  below :
oPdf.SetupCustomPrinter sPrinterName, 1, 8 but it does nothing more : only blank pages.
Ingo, I've tried also with the printoption pagescalling set on 2, but with no effects anymore. By the way, what is the difference between fit to pagper (1)  and Shrink large pages (2) ?
Thanks in advance.
Eddy

Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 03 Mar 09 at 4:28AM
Hi Eddy!

I think in the security settings of your pdf-document printing seems to be not allowed?
Fit means if it's too small (eg A5) it will be larger if the printer is A4 for example.
Shrink means (eg A3) compress it to see all on A4-printing.
You're right... That's actually not clear - "Fit" should be enough ;-)

Cheers, Ingo
 
Back to Top
Eddy View Drop Down
Beginner
Beginner


Joined: 17 Nov 08
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote Eddy Quote  Post ReplyReply Direct Link To This Post Posted: 04 Mar 09 at 3:29AM
Hi all,
I finally solved my problem !
It was very strange...
In fact, I was trying to print with a High quality (1) and the printer (an HP K8900) wasn't able to manage it ! If I change the quality to 2 or higher, it works.
Thank you Ingo and Delbeke for your help.
Eddy
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. About — Contact — Blog — Support — Online Store