title: scale PDF to single page
body: <p>Is there a simple way to scale the pdf created by cfdocument or cfpdf to a single page using CF8?  My output (a calendar) could possibly extend to page 2 depending on the number of events.  I'd rather scale the calendar to fit it in one page.  I assume I can create the pdf with cfdocument.  Use cfpdf to check the page numbers and loop while totalPages > 1 create the PDF with a lesser scale.</p>
  
  <p>psudo code:</p>
  
  <pre><code>pdfScale = 100
  cfdocument scale = "#pdfScale#"
  cfpdf action = "getinfo" name = "mypdf" 
  cfloop while mypdf.totalPages &gt; 1
  pdfScale = pdfScale -5
  cfdocument scale = "#pdfScale#"
  cfpdf action = "getinfo" name = "mypdf"
  /cfloop
  </code></pre>
  
  <p>Am I on the right track or am I missing something to make this easier?  Thanks.</p>