Welcome Guest Search | Active Topics | Sign In | Register

Error MVCToPDF.RenderAsPDF when html is too large Options
Gesdocument
Posted: Friday, September 19, 2014 9:39:10 AM
Rank: Member
Groups: Member

Joined: 5/23/2013
Posts: 24
Hi,
is possible than EO.Web 2013 produce a problem when I use MVCToPDF.RenderAsPDF and the html I want to render to PDF is too large?
I use MVCToPDF.RenderAsPDF to render an aspx file to pdf. The aspx is generated dinamically and buid a table with one tr row inside foreach object user in a foreach statement.
When the foreach statement has 50 users no problem, but if it has 200 users, I can't get the pdf file correctly, it shows an error.
If I render the aspx in a web page with 200 users (not to pdf), initially it shows an error of script when I try to scroll the page because the page is too large, but if I wait 60 seconds, the page shows ok finally and I can scroll to the final and showing ok,
Perhaps is this the problem (the script error initial when I try to scroll) that produces not render properly the pdf?

Thanks!
eo_support
Posted: Friday, September 19, 2014 12:11:10 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,196
Hi,

You can try to increase HtmlToPdf.Options.MaxLoadWaitTime and see if that helps. However you don't want to push the converter over the limits with large files. While we are always working very hard to improve the performance of the product, there always exists a limit on how large the HTML the component can handle. Yet the limit won't be clearly defined by number of rows, or number of pages, or number of pictures, etc. For example, a simple page full of text will run faster and take less memory than a page with tables. And a table with "regular" text will take less memory than a table with RTL text such as Arabic text. When the file you wish to convert is too large, the converter can run out of memory or times out in a unpredictable manner. It is not practical for us to "fix" such scenarios since this would be like trying to fix a boat that can only load 10 people to load 20 people. The only practical solution is to reduce the load in this case.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.