PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Fri Apr 19, 2024 4:05 pm

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Mon Aug 06, 2012 5:13 pm 
Offline

Joined: Wed Aug 01, 2012 2:14 pm
Posts: 2
I'm looping through my list, filling out a PDF Form, saving it to a temp file, opening said temp file, and attempting to insert that page into a new file for batch printing.

The first page in the PDF looks fine in the viewer, but the subsequent pages are all blank.

//Create Temp File
string tempPathName = Path.GetTempFileName();

//Save current form to Temp File
tempForm.Save(tempPathName);

//Open Temp File and import into batch file
PdfDocument formPage = PdfReader.Open(tempPathName, PdfDocumentOpenMode.Import);

//I've tried both of these and they both produce blank pages after the first page
batchForm.Pages.Add(formPage.Pages[0]);
batchForm.InsertPage(pageCounter, formPage.Pages[0]);

pageCounter++;



The thing is, when I open the file in the "tempPathName" every one of them opens correctly populated so I know that generation is working correctly.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 213 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group