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 - Imposing PDF
  FAQ FAQ  Forum Search   Register Register  Login Login

Imposing PDF

 Post Reply Post Reply
Author
Message
Barnabe42 View Drop Down
Beginner
Beginner
Avatar

Joined: 01 Feb 12
Location: Finland
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote Barnabe42 Quote  Post ReplyReply Direct Link To This Post Topic: Imposing PDF
    Posted: 01 Feb 12 at 10:43AM
Hello,
 
I am looking for a way to impose several PDFs into a bigger one.
I have customer having files in A4 and A3 format and they would like to merge them into one A0 file.
 
Is it possible to acheive using Quick PDF ?
 
/Eric
 
 
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: 01 Feb 12 at 12:34PM

Yes.  Basically you need to used the CapturePage and DrawCapturedPage functions.

Here is the basic logic that you would need to follow.

1. Create a blank A0 sized page.

  QP.NewDocument();
  QP.SetPageSize("A0");
  QP.SaveToFile("A0.pdf");

2. Merge all the required PDF's into a single PDF.

  QP.ClearFileList("MergeList");
  QP.AddToFileList"(MergeList", "a0.pdf");
  QP.AddToFileList("MergeList", "page1.pdf");
  QP.AddToFileList("MergeList", "page2.pdf");
  QP.AddToFileList("MergeList", "page3.pdf");

  QP.MergeFileList("MergeList", "merged.pdf");

  QP.LoadFormFile("merged.pdf", "");
  
   for (int i=1; i<=3 ; i++)  // QP.PageCount - 1 ???
  {
    QP.SelectPage(2);
    double wid = QP.PageWidth();
    double hgt  = QP.PageHeight();

    int capId = QP.CapturePage(2);   // Page 2 is capture and also deleted from the document.

    QP.SelectPage(1);
    QP.DrawCapturedPage(capId, i * 300, i * 300, wid, hgt);
  }

  QP.SaveToFile("imposed.pdf");

Back to Top
Barnabe42 View Drop Down
Beginner
Beginner
Avatar

Joined: 01 Feb 12
Location: Finland
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote Barnabe42 Quote  Post ReplyReply Direct Link To This Post Posted: 02 Feb 12 at 1:46PM
Thanks a lot, I was able to impose 3 pdfs into a single A0 pdf.


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