PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Sat Apr 27, 2024 6:25 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: Tue Nov 24, 2009 2:19 pm 
Offline
Supporter

Joined: Fri May 15, 2009 3:28 pm
Posts: 96
Hi,

Each time I add a page and tables etc. to that page, i call my RenderPgs() function, which calls renderer.PrepareDocument(). This ends up getting called lots of times and since it prepares the whole document everytime, the longer the number of pages, the longer PrepareDocument() takes to process.

I realise my code is fundamentally wrong in the way it works now (i presume i should only render pages once ALL pages have been added, but applying this to my existing code would cause it to really mess up when it comes to the PDFSHarp drawing bits) is there a way to:
Code:
int start = PdfDocument.PageCount();
renderer.PrepareDocument(start);

where it will start at the start page and ignore previous pages (as they are already rendered) and prepare until the end?

Mike


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 405 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