Hi Thomas, thanks a lot for your prompt reply, you're a legend!
Question no. 2 has been resolved
However, I'm still having some trouble creating multi-page pdf documents. I checked out your MixMigraDocAndPdfSharp sample, and its got the following 2 snippets of code:
// code snippet #1
static void SamplePage1(PdfDocument document)
{
PdfPage page = document.AddPage();
XGraphics gfx = XGraphics.FromPdfPage(page);
// code snippet #2
// You need always a MigraDoc document for rendering.
Document doc = new Document();
Section sec = doc.
AddSection();
// Add a single paragraph with some text and format information.
Paragraph para = sec.AddParagraph();
This still renders the document page by page, one paragraph at a time. What I'm looking for is to just input something like 10 pages of text, and get a 10-page pdf document in return.
My final objective is to export some content on a sharepoint portal to PDF. The challenge is to export it while keeping the look and feel (.aspx page in sharepoint, rendered using html and css) as similar to the original sharepoint page as possible. I'm not sure about the best approach to do this. Is there a way to export html+css to pdf directly (by parsing html+css to preserve the look and feel and then converting the required text to pdf)?