| A3 printing [SOLVED]
 
 Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
 Category:  For Users of the Library
 Forum Name:  I need help - I can help
 Forum Description:  Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
 URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=1018
 Printed Date: 31 Oct 25 at 3:15AM
 Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com
 
 
 Topic: A3 printing [SOLVED]
 Posted By: Eddy
 Subject: A3 printing [SOLVED]
 Date 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
 
 |  
 
 Replies:
 Posted By: DELBEKE
 Date Posted: 02 Mar 09 at 1:24PM
 
 
        
          | I don't know waht happens Perhaps setting the PaperSize? oPdf.SetupCustomPrinter sPrinterName, 4, 8 'Format A3 |  
 Posted By: Ingo
 Date 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;
 
 
 |  
 Posted By: Ingo
 Date 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
 
 |  
 Posted By: Eddy
 Date 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
 
 
 |  
 Posted By: Ingo
 Date 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
 
 
 |  
 Posted By: Eddy
 Date 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
 
 |  
 
 |