Print Page | Close Window

A4 to A3

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=2668
Printed Date: 07 Feb 26 at 8:19PM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: A4 to A3
Posted By: Nelson Castro
Subject: A4 to A3
Date Posted: 13 Jun 13 at 1:37PM
Hi! Please, how can I convert two pages A4 to a single page A3?  Thanks for any help!



Replies:
Posted By: AndrewC
Date Posted: 14 Jun 13 at 3:08AM

Nelson,

Here is some very simple code without error checking that will do what you need.  It assumes there are 2 A4 pages in your input file.

  QP.LoadFromFile("2pages.pdf");

  int capID = QP.CapturePage(2);

  QP.SetPageSize("A3");
  QP.SelectPage(1);
  QP.SetOrigin(1);
  QP.DrawCapturedPage(capID, QP.PageWidth()/2, 0, QP.PageWidth() / 2, QP.PageHeight());
  QP.SaveToFile("out.pdf");

Andrew



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk