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 > Sample Code
  New Posts New Posts RSS Feed - Create new pages and stamp text on each using C#
  FAQ FAQ  Forum Search   Register Register  Login Login

Create new pages and stamp text on each using C#

 Post Reply Post Reply
Author
Message
Rowan View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 10 Jan 09
Status: Offline
Points: 398
Post Options Post Options   Thanks (0) Thanks(0)   Quote Rowan Quote  Post ReplyReply Direct Link To This Post Topic: Create new pages and stamp text on each using C#
    Posted: 09 Sep 09 at 2:59AM
This C# sample code shows you how to programmatically create new pages and stamp text on each of the pages as they are created. In the for loop you could use any of the drawing, table, form field, etc, function to create dynamic PDFs on the fly. It's quick and easy.

---
private void btnNewPages_Click(object sender, EventArgs e)
{
    string LicenseKey = "...INSERT_LICENSE_KEY_HERE";
    int result;
    int page;
    int totalPages;

    QuickPDFAX0715.PDFLibrary qp = new QuickPDFAX0715.PDFLibrary();
    result = qp.UnlockKey(LicenseKey);

    if (result == 1)
    {
qp.NewPages(24);
totalPages = qp.PageCount();

for (page = 1; page <= totalPages; page++)
{
     qp.SelectPage(page);
     qp.DrawText(100, 500, "Page " + page);
}
qp.SaveToFile("NewPages.pdf");
    }
    else
    {
MessageBox.Show("Sorry, but the license key you provided could not be validated.");
    }
}
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