Free Support Forum - aspose.com

insertHtml table and hyperlink tag issue

Hi All


when using insertHtml anchor tag is not properly rendering when using with-in a table.

even if the anchor display is just 'abcd' in the below scenario, while rendering as pdf aspose api is considering the actual URL width instead of display text.


Please let me know if any workaround or fix for this issue.


Thanks

Ganesh



public class Utils

{

public static String TEMPLATE_PATH = "d:\\TEMPLATE_SPEC.doc";

public static void main(String[] args) {

try {

Document doc = new Document(TEMPLATE_PATH);

DocumentBuilder builder = new DocumentBuilder(doc);

builder.insertHtml("

abcd
");

doc.save("d:\\check.pdf");

} catch (Exception e) {

e.printStackTrace();

}

}




Hi Ganesh,

Thanks for your inquiry. Perhaps, you're using an older version of Aspose.Words; as with Aspose.Words v11.9.0, I am unable to reproduce this problem on my side. I would suggest you please upgrade to the latest version of Aspose.Words i.e. v11.9.0 and let us know how it goes on your side. I hope, this will help.

I have attached the output PDF file with this post. If you still face problem, please share your input Word document for investigation purposes.

Hi,

I have updated with latest jars and the problem is longer exists, many thanks for your quick reply with solution.

Many Thanks

Ganesh

Hi Ganesh,


Thanks for your feedback. Please feel free to ask if you have any question about Aspose.Words, we will be happy to help you.