We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Problem rendering whole html page

Thread ID:

Created:

Updated:

Platform:

Replies:

94851 Jun 4,2010 07:41 PM UTC Jun 8,2010 10:50 AM UTC ASP.NET Web Forms (Classic) 1
loading
Tags: PDF
Administrator [Syncfusion]
Asked On June 4, 2010 07:41 PM UTC

Hi, I have a HTML page that is just text and tables, when we convert it to pdf using html.FromString(), it only renders part of the page and not all of it. this might be just coincidental, but it always render up to 24 pages and after that the remaining pages are just blank pages. am I doing anything wrong?
I have attached a sample pdf of what gets rendered.
the page html is very simple:











Number Name Age
${row.Number} ${row.Name} ${row.Score}


The code I used to do the conversion is as follows:
public void RenderPdf(string physicalPath, string markup)
{
var pdf = new PdfDocument();
var page = pdf.Pages.Add();
var converter = new PdfUnitConvertor();
var width = converter.ConvertToPixels(page.GetClientSize().Width, PdfGraphicsUnit.Point);
using (var html = new HtmlConverter())
{
html.EnableJavaScript = false;
html.AutoDetectPageBreak = true;
html.EnableHyperlinks = false;
var meta = html.FromString(markup, physicalPath, ImageType.Metafile, (Int32)width, -1, AspectRatio.KeepWidth) as Metafile;
var mf = new PdfMetafile(meta);
mf.Quality = 100;
var format = new PdfMetafileLayoutFormat();
format.Break = PdfLayoutBreakType.FitPage;
format.Layout = PdfLayoutType.Paginate;
format.SplitTextLines = false;
format.SplitImages = false;
mf.Draw(page, new PointF(0, 0), format);
}
}

thank you so much, in advance, for your help.



Sample Report-20100604-191822_9a8d779c.zip

Angappan G [Syncfusion]
Replied On June 8, 2010 10:50 AM UTC

Hi Khilo,

Thank you for your interest in Essential Studio.

Could you please report these issues through Direct Trac Developer Support Systemhttps://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents because you can take the advantage of the expertise of a dedicated support engineer and a guaranteed response time and we hope you will take advantage of this system as well.

Please let us know if you have any queries.

Regards,
Angappan.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;