<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="http://syndication.webwiz.co.uk/rss_namespace/">
 <channel>
  <title>Debenu Quick PDF Library - PDF SDK Community Forum : merge two pdf&#039;s</title>
  <link>http://www.quickpdf.org/forum/</link>
  <description><![CDATA[This is an XML content feed of; Debenu Quick PDF Library - PDF SDK Community Forum : I need help - I can help : merge two pdf&#039;s]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 20 May 2026 05:10:59 +0000</pubDate>
  <lastBuildDate>Wed, 27 Oct 2021 14:24:28 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 11.01</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>www.quickpdf.org/forum/RSS_post_feed.asp?TID=3956</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Debenu Quick PDF Library - PDF SDK Community Forum]]></title>
   <url>http://www.quickpdf.org/forum/forum_images/QPDF_Forum_Title.png</url>
   <link>http://www.quickpdf.org/forum/</link>
  </image>
  <item>
   <title><![CDATA[merge two pdf&#039;s : Ok I figured out to overlay multiple...]]></title>
   <link>http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15920.html#15920</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=3085">cprins</a><br /><strong>Subject:</strong> 3956<br /><strong>Posted:</strong> 27 Oct 21 at 2:24PM<br /><br />Ok I figured out to overlay multiple pages with multiple pages<div><br></div><div>The function takes two pdf's&nbsp;</div><div><ul><li><span style="white-space:pre">	</span>template with the letterhead</li><li><span style="white-space:pre">	</span>OriginFile with the text.</li></ul></div><div><br></div><div>The function can handle a letterhead with 1, 2 or 3 pages</div><div><ul><li>With one page you only have the letterhead on each page</li><li>With 2 pages you have 1 frontpage and the rest of the document is overlayed with page 2 of the template</li><li>With 3 pages you have 1 frontpage and the other pages take page 2 or 3 of the template depending on being a odd or even page</li></ul><div>If you have any commands or suggestion please let me know</div></div><div><br></div><div><table width="99%"><tr><td><pre class="BBcode"></div><div><div>procedure TPDF.LetterHead(template,Text:string);</div><div>var</div><div>&nbsp; TextDocID: Integer;</div><div>&nbsp; TemplateDocID: Integer;</div><div>&nbsp; FrontPageID:integer;</div><div>&nbsp; EvenPageID:integer;</div><div>&nbsp; OddPageID:integer;</div><div>&nbsp; OverlayID:integer;</div><div>&nbsp; PageHeight: Double;</div><div>&nbsp; PageWidth: Double;</div><div>&nbsp; LetterheadCount:integer;</div><div>&nbsp; i: Integer;</div><div>begin</div><div><br></div><div>qp.LoadFromFile(Text,'');</div><div>TextDocID := qp.SelectedDocument();</div><div>qp.LoadFromFile(template,'');</div><div>TemplateDocID := qp.SelectedDocument();</div><div>LetterHeadCount:=qp.PageCount;</div><div>qp.SelectDocument(TextDocID);</div><div>qp.MergeDocument(TemplateDocID);</div><div><br></div><div>OddPageID := 0;</div><div>EvenPageID := 0;</div><div>FrontPageID := 0;</div><div><br></div><div>case LetterheadCount of</div><div>1: begin</div><div>&nbsp; &nbsp; FrontPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp;end;</div><div>2: begin</div><div>&nbsp; &nbsp; EvenPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp; FrontPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp;end;</div><div>3: begin</div><div>&nbsp; &nbsp; OddPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp; EvenPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp; FrontPageID := qp.CapturePage(qp.PageCount);</div><div>&nbsp; &nbsp;end;</div><div>end;</div><div><br></div><div><br></div><div>for i := 0 to qp.PageCount-1 do</div><div>begin</div><div>&nbsp;OverlayID:=0;</div><div>&nbsp;case LetterheadCount of</div><div>&nbsp;1: begin</div><div>&nbsp; &nbsp; &nbsp; &nbsp;OverlayID:=FrontPageID;</div><div>&nbsp; &nbsp; end;</div><div>&nbsp;2: begin</div><div>&nbsp; &nbsp; &nbsp; if i=0 then</div><div>&nbsp; &nbsp; &nbsp; &nbsp;OverlayID:=FrontPageID</div><div>&nbsp; &nbsp; &nbsp;else</div><div>&nbsp; &nbsp; &nbsp; OverlayID:=EvenPageID;</div><div>&nbsp; &nbsp; end;</div><div>&nbsp;3: begin</div><div>&nbsp; &nbsp; &nbsp;if i=0 then</div><div>&nbsp; &nbsp; &nbsp; OverlayID:=FrontPageID</div><div>&nbsp; &nbsp; &nbsp;else</div><div>&nbsp; &nbsp; &nbsp;begin</div><div>&nbsp; &nbsp; &nbsp; if Odd(i+1) then</div><div>&nbsp; &nbsp; &nbsp; &nbsp;OverlayID:=OddPageID</div><div>&nbsp; &nbsp; &nbsp; else</div><div>&nbsp; &nbsp; &nbsp; &nbsp;OverlayID:=EvenPageID</div><div>&nbsp; &nbsp; &nbsp;end;</div><div>&nbsp; &nbsp;end;</div><div>&nbsp;end;</div><div><br></div><div>&nbsp;if OverlayID&gt;0 then</div><div>&nbsp;begin</div><div>&nbsp; qp.SelectPage(i+1);</div><div>&nbsp; PageHeight := qp.PageHeight();</div><div>&nbsp; PageWidth := qp.PageWidth();</div><div>&nbsp; qp.DrawCapturedPage(OverlayID, 0, PageHeight, PageWidth, PageHeight);</div><div>&nbsp;end;</div><div><br></div><div>end;</div><div><br></div><div>qp.SaveToFile('H:\output.pdf');</div><div><br></div><div>end;</div></div><div><br></div><div></pre></td></tr></table></div><div><br></div><div><br></div><div><br></div>]]>
   </description>
   <pubDate>Wed, 27 Oct 2021 14:24:28 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15920.html#15920</guid>
  </item> 
  <item>
   <title><![CDATA[merge two pdf&#039;s : Hi Ingo,Thaks for your responseour...]]></title>
   <link>http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15914.html#15914</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=3085">cprins</a><br /><strong>Subject:</strong> 3956<br /><strong>Posted:</strong> 19 Oct 21 at 8:45PM<br /><br />Hi Ingo,&nbsp;<div><br></div><div>Thaks for your response</div><div>our first email conversation started already in 2009 so I'm here for a while (In those days I created a pdf viewer for Delphi which from time to time I still see some code passing by)</div><div><br></div><div>However due to the ambigous term "merge" I was not able to find what I'm was looking for.</div><div><br></div><div>I think your second options is worthwhile&nbsp; diging in to.<br></div><div><br></div><div>As soon as I have my code up and running I will let you know and share it with the Forum.</div><div><br></div><div>A other might be to stream the pdf's to bitmaps and "merge"them together and put them back in a new pdf.</div><div>So indeed the idea is to overlay two pdf's (;etterhead with additonal text)</div><div><br></div><div>Thanks</div><div>Christian</div><div><br></div>]]>
   </description>
   <pubDate>Tue, 19 Oct 2021 20:45:49 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15914.html#15914</guid>
  </item> 
  <item>
   <title><![CDATA[merge two pdf&#039;s : Hi Christian,registered in the...]]></title>
   <link>http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15913.html#15913</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=111">Ingo</a><br /><strong>Subject:</strong> 3956<br /><strong>Posted:</strong> 19 Oct 21 at 6:51PM<br /><br />Hi Christian,<br><br>registered in the forum since 2018 and didn't find helpful samples? ;-)<br>I think you want to combine the two pages on one new page - so reduce for example two DIN A4 pages to DIN A5 and put them together on one new DIN A4?<br>Here's a kb-document giving you more than an idea how to do it:<br>https://www.debenu.com/kb/merge-content-from-multiple-pages-into-one-page/<br>If you want to combine an invoice template with real content to one filled out invoice here's another sample:<br>https://www.debenu.com/kb/overlay-one-pdf-onto-another-pdf-programmatically/<br><br>&gt;&gt; the starting point for all questions: http://www.quickpdf.org/ &lt;&lt;<br>&gt;&gt; search in all ressources: https://www.debenu.com/docs/pdf_library_reference/Search.php &lt;&lt;<br>&nbsp;<br><br><br>]]>
   </description>
   <pubDate>Tue, 19 Oct 2021 18:51:39 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15913.html#15913</guid>
  </item> 
  <item>
   <title><![CDATA[merge two pdf&#039;s : Hi thereAlthough there is a merge...]]></title>
   <link>http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15912.html#15912</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=3085">cprins</a><br /><strong>Subject:</strong> 3956<br /><strong>Posted:</strong> 19 Oct 21 at 3:57PM<br /><br />Hi there<div><br></div><div>Although there is a merge function in quickPDF it isn't doing the thing I want</div><div>Imaging you have two pdf's (both have 1 page)</div><div>Now I want to have as an output 1 document with 1 page containing the two pdf's on top of each other</div><div>This is probably been questioned befor but I can't find the right search term</div><div><br></div><div>So is it possible to merge two pdf's to 1 without adding the both pdf's to each other</div><div><br></div><div>I hope I made myself clear what I want</div><div><br></div><div>Thaks in advance&nbsp; &nbsp;</div>]]>
   </description>
   <pubDate>Tue, 19 Oct 2021 15:57:01 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/merge-two-pdfs_topic3956_post15912.html#15912</guid>
  </item> 
 </channel>
</rss>