I need to fit an HTML file to an A4 paper size. As in the attachments I'm currently using the "test.html" to generate PDF files.
My current output is indicated by the "NOT_OK.pdf". I used the following web site do generate the "IS_OK.pdf" pdf file:
http://pdfcrowd.com/#convert_by_upload
I tried to set PageHeight, PageWidth, PdfScalingFactor, PageLayout, PageMode, InitialPdfExactZoom and others properties to distinct values, but nothing seems to work for me, maybe I'm missing something.
Does anyone have any code sample that does the same thing as the sample in web site above ?I'm using the code below
FileStream fileStream;
fileStream = new FileStream(@"C:\test.pdf", FileMode.CreateNew);
c.convertFile(@"C:\test.html", fileStream);
c.setPageHeight("297mm");
c.setPageWidth("210mm");
fileStream.Close();
Thanks in advance.