Custom resources folder while converting PDF to Html

Hi,

I am trying to convert several PDF to Html. The PDF files are created by us and mostly uses same fonts. While exporting PDF to Html the fonts are exported into _files folder. If we are converting 100 Pdf files, it exports the same font on all 100 _files folder. Is there any way to use custom font folder and export the font only if it does not exists in that folder and if the font is already exists then use the reference of that font?

@Sri79,

Can you please share source files so that we may further investigate to help you out. Also please share sample code with us.

@Adnan.Ahmad

Please use the sample files provided in Exception"An item with same key has already been added" using Aspose.PDF for .NET.

There are two copies of same sample file. What we are trying to achieve is if we export these pdf files to html, it should export the font and other resources in a custom folder only once. It should not export the copy of same font multiple times. If a font is already present in a custom folder it should just use the reference of that file instead of exporting it again.

@Sri79,

I have observed your requirements and created a investigation ticket with ID PDFNET-47617 either it it possible using Aspose.PDF or not. I request for your patience and we will share good news with you soon.

@Adnan.Ahmad

I would like to use one resource folder to store image, font, svg, css files, particularly when we split the pdf and save as html. The css can be one combined css for all splitted html files. By this way, when we load these html files in browser all css, font, images will be downloaded only once and will be used from cache. So when loading other splitted html files, the file will be loaded much faster.

In one of our scenario, we tried to save the pdf with 100 pages (split each page as individual pdf and created html from that file) created around 900 additional files (like css, image, svg, font, etc). However, if we save the entire pdf as single html it created less than 200 additional files.

Currently, it creates resource folder separately for each page. If we have same images, font on multiple pages, they are extracted separately and loaded separately in browser.

@Sri79,

I like to inform that we are looking into this and will share feedback with you regarding this soon.