I currently have a file that was generated elsewhere from HTML into PDF, which I am editing using GDPicutre.
I save the files that were referenced in HTML localy and then I embed into PDF.
My problem is, the original HTMl links are (in the newly created PDF file) converted to annotations.
By using this code, I am able to read the ActionURI (which is set to local files by my other HTML -> PDF SDK when the conversion from HTML link to local files occurs) using this code:
Code: Select all
string[] Files = Directory.GetFiles(Temp_Attachements_Dir);
for (int i = 0; i < Files.Length; i++)
{
Output_PDF.EmbedFile(Files[i], Path.GetFileName(Files[i]), "");
}
count = Output_PDF.GetAnnotationCount();
for (int i = 0; i < count; i++)
{
Output_PDF.GetActionURI(Output_PDF.GetAnnotationActionID(i));
}
Is there any way to change this Annotation to point at the file I embeded into PDF and not at the local file, so when I click the link in the PDF (opened in acrobat for example), it opens the attachment / opens the attachment tab ?
I attached a sample PDF file showing my problem (it references local paths, but also has the same files as attachments).