0 Replies Latest reply on Nov 20, 2016 6:00 PM by pdfUser1

    Need help modifying a little bit of javascript?

    pdfUser1 Level 1

      I'm using Acrobat X on a Mac. I have this bit of javascript (see below). It does just the opposite of what I'm trying to do. I want to flatten the Stamps, Lines, Call-Out text boxes and any other type of annotation and not effect the buttons and input fields (or any other fields in the doc). Just flatten the annotations. Can someone help me out? Here's the script and a thank you.

       

      Script:

      this.syncAnnotScan();

      var annots = this.getAnnots();

      for (var i = 0; i < annots.length; i++) {

      annots[i].print = (annots[i].type!="Stamp");

      }

      flattenPages(0,numPages-1,1);

      this.syncAnnotScan();

      annots = this.getAnnots();

      for (var i = 0; i < annots.length; i++) {

      annots[i].print = true;

      }