Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.

Wed Aug 31, 2016 12:21 am

Hello.
I need to generate A3 pdf from html at three copies.

my code:
Code: Select all
var document = new PdfDocument { PageSettings = new PdfPageSettings { Size = PdfPageSize.A3 } };

document.LoadFromHTML(url, false, false, false, new PdfPageSettings { Size = PdfPageSize.A3 });
                       
var template = document.Pages[0].CreateTemplate();
for (int i = 0; i < 2; i++) {
    var newPage = document.Pages.Add(PdfPageSize.A3);
    newPage.Canvas.DrawTemplate(template, new PointF(0, 0));
}


but something going wrong, first page actualsize and canvas is always a4 and my final pdf looks not good

Image

Any ideas, what can i do with it?

kirill4012
 
Posts: 1
Joined: Wed Aug 31, 2016 12:01 am

Wed Aug 31, 2016 2:45 am

Dear kirill4012,

Thanks for your inquiry.
I have tested your scenario with the latest Spire.PDF Pack(Hot Fix) Version:3.7.198 , it works fine. Please try to use this version.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Fri Sep 02, 2016 9:07 am

Dear kirill4012,

Did you test the hotfix ? Has your issue been resolved ?

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Return to Spire.PDF