title: How do I move page one of a pdf to the last page?
body: <p>I use Adobe Acrobat Pro 9 at work to edit a large number of scanned pdf documents. These are not OCRed. The information I need to quickly mail these documents out are on the first page, but my boss would like this page at the back. I can move the first page to the back using thumbnails, but this gets tedious with a large number of pdfs that are 20+ pages. So far, I am trying to modify a script I found from Bremen_Matt's post:</p>
  
  <pre><code>for (i = 0; i &lt;= this.numPages/2-1; i++)
      this.movePage(this.numPages-1,this.numPages/2-i-1);
  </code></pre>
  
  <p><a href="https://stackoverflow.com/questions/13313267/how-to-write-javascript-to-reorder-pages-of-a-pdf-document">How to write javascript to reorder pages of a pdf document?</a></p>
  
  <p>I can almost get it to work, but when I try:</p>
  
  <pre><code>for(i=0;i&lt;=this.numPages/2-2;)
      this.movePage(this.numPages-1);
  </code></pre>
  
  <p>or</p>
  
  <pre><code>for(i=0;i&lt;=this.numPages;i)
       this.movePage(this.numPages-1);
  </code></pre>
  
  <p>I wind up crashing the program. Do you have any thoughts? Thank you!</p>