We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Hyperlink created with aspose does not comes on the PDF

Hi Team,

Please help me on this urgent issue.

I am creating a word document with a html file having hyperlink tag. The Word file created has the hyperlink along with the Bookmark name but while sending the same word file to Indesign it is not coming in the PDF generated. Also, when I try creating the word file manually with Microsoft tool with the same hyperlink and name and when I send it to Indesign the generated PDF has the hyperlink and works well on clicking the hyperlink on PDF.

Thanks for any help in advance.

Sonam Arora



Hi Team,

Any update on the above issue as it is the crucial issue in our application.

Thanks
Sonam

Hi Sonam,

Thanks for your inquiry. You are using an older version of Aspose.Words. I suggest you please use the latest version of Aspose.Words for Java 14.6.0.

If you still face problem, please share here the steps which you are following to convert Word document to Pdf using Adobe inDesign tool or any plugin e.g xPresso. Please share download link of plugin if you are using any.

As soon as you get these pieces of information to us we’ll start our investigation into your issue.

Hi Team,

PFA the attached utility to generate the Word file and the sample input html file which we use as input to indesign.

Please let me know if i m missing any key code in the utility.

Thanks
Sonam

Hi Sonam,

Thanks for sharing the code. I have worked with your shared code and have found that you are simply inserting html into document and save it to Docx. There is no issue with output Docx.

To reproduce the issue which you are facing we need following detail as requested in my previous post.

  • Please share here the steps which you are following to convert Word document to Pdf using Adobe inDesign tool or any plugin e.g xPresso.
  • Please share download link of plugin if you are using any. So, I will have the same plugin as of yours.


sonam.arora:

The Word file created has the hyperlink along with the Bookmark name but while sending the same word file to Indesign it is not coming in the PDF generated. Also, when I try creating the word file manually with Microsoft tool with the same hyperlink and name and when I send it to Indesign the generated PDF has the hyperlink and works well on clicking the hyperlink on PDF.

There is no bookmark in input html. Please share some more detail about this query along with following details.
  • Please attach the output Pdf file that shows the undesired behavior.
  • Please attach the output Pdf file that shows the desired behavior.

As soon as you get these pieces of information to us we’ll start our investigation into your issue.

Hi Tahir,

You are correct, we are using only hyperlink and we are not using any bookmarks. The input.html only has a hyperlink text as GOOGLE which points to google website.

Let me give you a scenario to explain the issue. We have 2 word documents having text GOOGLE as hyperlink pointing to the google website(similar to the input html file shown in the earlier attachment). The first document we have created using Aspose using the code provided in the earlier post. The second one we have created manually using Microsoft Word 2010. We use Adobe inDesign for converting these word documents to PDF. The issue is that the pdf created using the manually created word document displayes the text along with the hyperlink which on clicking points to the google website, but the pdf created using the Aspose created word file is not displaying the text(it is blank).

I have replied as [Sonam] to your queries below:

  • Please share here the steps which you are following to convert Word document to Pdf using Adobe inDesign tool or any plugin e.g xPresso.
    [SONAM]:We are using Adobe inDesign tool to convert into PDF. We send the file path of the document in the XML in the webservice call to inDesign. The file path in the xml is as follows ecm::DCTM:/TempFiles/output_1stJuly_0903c02a8047d5cb.docx
  • Please share download link of plugin if you are using any. So, I will have the same plugin as of yours.
    [SONAM]:We are not using any other plugin

We wont be able to share the pdf documents as the pdf contains the company logo.

Desired PDF document has the text GOOGLE. When we control click on the text it opens up the google website.

Undesired PDF document does not contain the GOOGLE text( the space where the text should be present is blank).

Kindly let me know if you have got all the pieces of information needed for your investigation.

Thanks,

Sonam.

Hi Sonam,

Thanks for sharing the detail. I have tested the scenario using the documents generated via MS Word and Aspose.Words. In both cases, hyperlink is not available in output Pdf file. Please check the attached documents.

Following steps are used to generated the Docx using MS Word.
1) Open input.html in MS Word 2010
2) Save the document to Docx using ‘Save as’ Options

Following steps are used to generated the Docx using Aspose.Words
1) I have used the same code (using insertHTML) which you shared to generated the output Docx.

I have performed the following steps to import Word document into inDesign and export it to Pdf.

1) File->New Document
2) File->Place-> (open the word file)
3) File->export to Pdf

Please check the attached Docx and Pdf documents.

Hi Tahir,

I have attached the screenshots of the pdf's (in TestWord.zip) that were created using Microsoft Word 2010 (testwordcreatedbyme.png) and using aspose generated word file (testwordaspose.png). There is definitely some difference in the word file created using Aspose which the InDesign is not able to read. As you can see in the screenshot that the file created using Word 2010 is correctly converted in PDF format along with the bookmark but the content from the aspose created word file is not displayed in the PDF.

Kindly investigate the issue and guide us to get the results in the pdf using the Aspose created word file.

Thanks,

Sonam.

Hi Sonam,

Thanks for your inquiry. Unfortunately, it is difficult to say what is the problem without reproducing it at our end.

I have created a Word document using MS Word 2010. Please convert the attached Word document to Pdf using your service and share the output here for our reference.

sonam.arora:

[SONAM]:We are using Adobe inDesign tool to convert into PDF. We send the file path of the document in the XML in the webservice call to inDesign. The file path in the xml is as follows <file_path>ecm::DCTM:/TempFiles/output_1stJuly_0903c02a8047d5cb.docx</file_path>

Could you please share how to setup the same service environment at our end? Please share some detail about your service. We need to setup the same setting at our end to reproduce this issue. Unfortunately, we can not log this issue without reproducing it at our end.

You may create a standalone/runnable simple application (for example a Console Application Project) that demonstrates the code you used to generate your output document.

Hi Tahir,

As requested I have used the attached word document to convert it to pdf using our application. For your reference I have shared the screenshot (New Bitmap Image.png) which shows that the text is visible but the hyperlink is missing.

I have attached the word file created manually using Word 2010 (New Microsoft Word Document.docx ), but this is giving me expected output i.e. text with hyperlink. Kindly share the output of this file with us.

Thanks,

Sonam.

Hi Sonam,

Thanks for sharing the output in image.

tahir.manzoor:


sonam.arora:

[SONAM]:We are using Adobe inDesign tool to convert into PDF. We send the file path of the document in the XML in the webservice call to inDesign. The file path in the xml is as follows <file_path>ecm::DCTM:/TempFiles/output_1stJuly_0903c02a8047d5cb.docx</file_path>

Could you please share how to setup the same service environment at our end? Please share some detail about your service. We need to setup the same setting at our end to reproduce this issue. Unfortunately, we can not log this issue without reproducing it at our end.

You may create a standalone/runnable simple application (for example a Console Application Project) that demonstrates the code you used to generate your output document.


As per your investigations, document
generated via MS Word works in your indesign environment and document
generated via Aspose.Words does not work in indesign. We understand this detail.

However, it is difficult to say what is the problem without having the same environment as of yours. Please share the above requested detail. As soon as, we have the same indesign environment as of your, we’ll start our investigation into your issue.

Hi Tahir,

We have found some answer as to why the links are not enabled in the pdf you create using InDesign.

The text below is present at the link : https://forums.adobe.com/message/1312375
In InDesign, Export, select pdf, and n the export Dialog box, be sure Include Hyperlinks is checked. Hyperlinks are not active in InDesign; they become active when you export to Pdf.
Could you kindly check if this setting is set before you export to PDF ? Let us know your results.
Thanks,
Sonam.

Hi Sonam,

Thanks for your inquiry. I have selected the hyperlink option while exporting the Pdf file in indesign. See the attached image and documents for detail. I have attached both Word and Pdf documents with this post for your kind reference.

The WordOut.docx is generated by using the steps below:
1) Open input.html in MS Word 2010
2) Save the document to Docx using ‘Save as’ Options

Hi Tahir,

For our reference can you kindly share the pdf generated using the document attched using your InDesign.

Thanks,

Sonam.

Hi Team ,

Any update for the above request?

Thanks
Sonam Arora

Hi Tahir,

Please find attached the files with their description :
- Testing hyperlink Aspose - Word file created using Aspose API having text with hyperlink
- Testing hyperlink Manual - Word file created Manually having text with hyperlink.
- Testing hyperlink Aspose_PDF_ScreenShot - PDF screenshot(cropped) generated using In design tool.
- Testing hyperlink Manual_PDF_ScreenShot - PDF screenshot(cropped) generated using Indesign tool.
- WordDocHyperlinksfromInDesign – Internal steps that are used to render a PDF file from word document.

As you can see from files attached ,
- PDF generated from aspose created word file renders nothing.
- PDF generated from manually created word file renders text as well as hyperlink.

Issue : Why aspose generated word file not able to render anything on PDF using Indesign whereas Manually created renders everything??

Please check from your side the PDF generated using Indesign from attached word files following steps as mentioned in WordDocHyperlinksfromInDesign.
Kindly provide a workaround for this as this is quite a critical issue in our application.

Appreciate for soon reply.
Thanks

Regards
Sonam Arora

Hi Sonam,

Thanks for your inquiry.

sonam.arora:

For our reference can you kindly share the pdf generated using the document attched using your InDesign.

Please find the output document in attachment. The shared document (WordFile.docx) is not generated from input.html. You inserted the hyperlink using MS Word. In this case, the issue exists in Aspose.Words generated document when used with indesign.

If I insert the hyperlink using DocumentBuilder.InsertHyperlink method (instead of inserting input.html in Document) and export the generated document to Pdf using indesign, the hyperlink is not available in output Pdf. However, the output is not blanked as of yours.

For the sake of correction, I have logged this problem in our issue tracking system as WORDSNET-10508. I have linked this forum thread to the same issue and you will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.
sonam.arora:


Please find attached the files with their description :
- Testing hyperlink Aspose - Word file created using Aspose API having text with hyperlink
- Testing hyperlink Manual - Word file created Manually having text with hyperlink.
- Testing hyperlink Aspose_PDF_ScreenShot - PDF screenshot(cropped) generated using In design tool.
- Testing hyperlink Manual_PDF_ScreenShot - PDF screenshot(cropped) generated using Indesign tool.
- WordDocHyperlinksfromInDesign – Internal steps that are used to render a PDF file from word document.

As you can see from files attached ,
- PDF generated from aspose created word file renders nothing.
- PDF generated from manually created word file renders text as well as hyperlink.

Issue : Why aspose generated word file not able to render anything on PDF using Indesign whereas Manually created renders everything??

The document (Testing hyperlink Aspose.docx) is not correct. Please check the size of this document. It is 1KB. When I open this document in MS Word, I get corrupted document message. This is the reason you are getting the blank output Pdf file.

Hi Tahir,
Appreciate for your quick response ,Two points to note here :
1. Kindly log the issue in WORD JAVA instead of WORD NET.We are working on Java components.
2.For the Second issue : Kindly find attach the below file.The file got corrupted while uploadingin earlier post.
- Testing hyperlink Aspose - Word file created using Aspose API having text with hyperlink

Please generate the PDF of attached word file using the steps defined in WordDocHyperlinksfromInDesign file .

In our case PDF renders nothing.as explained earlier.Please check this asap.

Thanks
Sonam Arora

Hi Sonam,

Thanks for your inquiry. Please find the attached output Pdf file generated via indesign tool.

Please note that the latest version of
Aspose.Words for Java is completely auto-ported from .NET, i.e. we do
not write code for Aspose.Words for Java; it is generated out
automatically from C# code of Aspose.Words for .NET. In your case, the
issue that was logged with WORDSNET prefix would be auto
resolved in Java variant of Aspose.Words as well.

Hi Tahir,

We have updated some information/steps to make more clear on the reported issue.

Please find attach the files:
- Testing hyperlink Aspose - It is the word file created by the utility attached (using Aspose API). The html file which has a hyperlink was passed as input to the Utility. The generated word file is placed in the InDesign to export a PDF. The generated PDF file has the hyperlink text but not the link.
- Testing hyperlink Aspose_PDF_Screen Shot - PDF screenshot(cropped) generated using In design tool.

- WordDocHyperlinksfromInDesign -- This word file is created manually with text hyperlink and placed in the InDesign to export a PDF. The generated PDF file has the both the hyperlink text and the link..

Issue : Why aspose generated word file not able to render hyperlink (text is rendering) on PDF using Indesign whereas Manually created renders hyperlink with text??
Secondly, If we have the direct link (http://www.google.com) in Aspose word file,it shows the hyperlink in PDF. Only the Text Hyperlinks ("google" text pointing to http://www.google.com) are not working with Aspose.

It would be great if we could get a quick fix for this as this is critial business requirement.


Thanks
Sonam