I have done like this for generating pdf at runtime when i click on the print button
The process is like this when I click on the print button the pdf is generated with fol
Extract from http://pdfsharp.codeplex.com/releases/view/37054:
If you favor speed: stay with PDFsharp 1.30. If you favor small PDF
files: use PDFsharp 1.31. Future versions of PDFsharp will support
both modes (favour speed and favour size).