After Merging Pdfs, Cursor Position is in Last Page

Last post 02-11-2011, 3:58 AM by balu949. 2 replies.
Sort Posts: Previous Next
  •  02-10-2011, 5:52 AM 284741

    After Merging Pdfs, Cursor Position is in Last Page .NET

    Attachment: Present (inaccessible)
    Hi Friends,

    I have a problem related to PDFs merging.
    using Aspose. PDF.Kit .
    When two PDFs are merged, They are merging properly.But the issue is when I tried to open it Cursor is in Last page of the document.

    So Could you help me how to get the cursor position in the first page of the document.

    Thanks & Regards
    Balu.

    Sitaramaiah E
    Filed under: Aspose.Pdf.Kit
     
  •  02-11-2011, 1:13 AM 284965 in reply to 284741

    Re: After Merging Pdfs, Cursor Position is in Last Page

    Hi Balu,

    This issue is caused due to the fact that the second document contains OpenAction method with GoTo command which moves the focus to the first page. That's why, when merged the OpenAction command executes and moves focus to the first page of the second PDF.

    There are two options: either don't add the OpenAction command in the original PDF or call the RemoveDocumentOpenAction method on the merged output PDF as shown below:

                      PdfContentEditor contentEditor = new PdfContentEditor();
                      contentEditor.BindPdf("ray380473118322011.pdf");
                      contentEditor.RemoveDocumentOpenAction();
                      contentEditor.Save("output.pdf");

    I hope this helps. If you have any further questions, please do let us know.
    Regards,

    Shahzad Latif - [Follow me on Twitter!]
    Support Developer/Developer Evangelist
    Aspose Sialkot Team
    Aspose - Your File Format Experts

    Keep in touch! We're on Twitter and Facebook
     
  •  02-11-2011, 3:58 AM 285013 in reply to 284965

    Re: After Merging Pdfs, Cursor Position is in Last Page

    Hi shahzad,
    Issue was fixed.
    Now it is working fine.
    A Big Thank you for your support.

    Regards
    Balu

    Sitaramaiah E
     
View as RSS news feed in XML