Hi,
I am converting a pdf document to html. The underlines in pdf are getting converted as an image in html. But, I want underlines as either
tags or some html code instead of an image. Can you please suggest a solution for this ?
Hi,
I am converting a pdf document to html. The underlines in pdf are getting converted as an image in html. But, I want underlines as either
@RV_2348
Please provide the code fragment and document used.
I tried to do this using the code
var pdfDocument = new Document();
Aspose.Pdf.Page page = pdfDocument.Pages.Add();
page.Paragraphs.Add(new TextFragment("Header"));
var htmlFragment = new HtmlFragment("<u>underline text</u>");
page.Paragraphs.Add(htmlFragment);
pdfDocument.ProcessParagraphs();
pdfDocument.Save(myDir + "output.html", new HtmlSaveOptions());
but it doesn’t work that way either - I’ll set tasks to the development team.
Code fragment is like :
Aspose.Pdf.Document pdfDocument = new Aspose.Pdf.Document(FolderToProcess + qbankName);
String fileName = qbankName.Replace(".pdf", “”);
pdfDocument.Save(CombinedHtmlOutPutPath + fileName + “.html”, GetHtmlSaveOptionsPDFToHTML());
I am attaching screenshot of a page in pdf:
image.png (35.1 KB)
and the underline is being saved as an image as shown in the attachment
img_03.png (17.3 KB)
I took the generated pdf document with text with underlining
WithUnderLine.pdf (340.2 KB)
and using code converted it to html.
var pdfDocument = new Document(myDir + "WithUnderLine.pdf");
pdfDocument.Save(myDir + "output.html", new HtmlSaveOptions());
With underlining and without pictures.
Please attach a document in pdf format for which what you are writing about occurs.
@RV_2348
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.
Issue ID(s): PDFNET-55564,PDFNET-55570
You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.
@RV_2348
I set two tasks for the development team:
PDFNET-55564 - NullReferenceException trown when converting pdf with HtmlFragment only, to html
PDFNET-55570 - Underline text not showing after converting pdf with HtmlFragment to html