0 Replies Latest reply on Mar 9, 2010 9:20 AM by E_donny

    replace cover page of PDF with applescript in Acrobat

    E_donny Level 1

      I tried replacing a cover page in a PDF document with the following code but got a "doesn’t understand the replace pages message." What am I not getting here? I'd like to fill a folder with new covers and have them wind up replacing the covers of PDF files, or page 1 with covers that have the same file name. This is my starting point.



      tell application "Adobe Acrobat Pro"

      set docPgToBe_replaced to "Macintosh HD:Users:don_feldman:Desktop:Switch_Chapter_ Covers:chapter PDF:9780071714921.pdf"

      set SourceOfNewPage to "Macintosh HD:Users:don_feldman:Desktop:Switch_Chapter_ Covers:cover PDF:9780071714921.pdf"


      replace pages docPgToBe_replaced over 1 from SourceOfNewPage starting with 1 number of pages 1

      save docPgToBe_replaced

      end tell