I am using Aspose.pdf version 220.127.116.11 to create reports from my asp.net mvc website. The packet has a coversheet that is converted from html and concatenated to an existing pdf. I am creating 3-150 of these documents and returning them as a zip.
When I convert the html to pdf I am getting multiple System.ArgumentException in System.Drawing.dll ("Font 'zapfdingbats' cannot be found") caught exceptions when I create a new pdf from html. I am also getting a couple 'System.Runtime.InteropServices.ExternalException' in System.Drawing.dll ("A generic error occured in GDI+.") exceptions. See the attached screenshot below.
I am not sure if this is the reason but the conversion from html to pdf seems to take longer than expected. I also notice that the creation of ~5 pdfs that range from 1 to 15 pages of text causes the memory load on the server to go up by over 200MB and it doesn't seem to go back down after future garbage collections.
This gives me concern where I will need to be able to create many many more similar pdfs reasonably quickly for my users.
- Is there something that needs to be installed on the server to get rid of these exceptions?
- These documents are being packaged and sent to the end user, but the downloaded zip is less than 1MB and the unzippped size is less than 2MB. Is there something I can do to reduce the memory load?
The html that gets converted is very simple:
var inPacketCount = ((int?)ViewBag.InPacketCount).GetValueOrDefault();
@Model.CourseWorkRequirement.Title - @Html.Raw(Model.CourseWorkRequirement.WorkPeriodRangeText)
@inPacketCount exams delivered to @Model.InstructorText: