You don't have to use the 239-page PDF as your input (template) PDF
document.  Instead, you can use it as an external graphic resource, and
specify the desired pages with the FusionProResource.pagenumber
property.  If you use inline graphics in a text frame with overflow
pages, you can insert a variable number of pages for each output record.

Here are the steps to take to accomplish this:

* Start with a new input PDF document.  (You can start from a blank
one-page document by saving or printing a blank document to PDF from
another application.)  The page size should be the same as in the PDF
from which you are including the pages.

* Define the data source for the document.  (You can import from your
original input PDF.)

* Set a text frame that completely covers the page, starting at X and Y
of zero.  You may need to extend the width and depth of the page by a
bit.

* Insert an Overflow page, duplicating the existing Body page.  Set the
text frame as the overflow destination.  (Check the "Overflow To" box on
the Text Frame palette.)

* Create a Text rule like the one below.  Make sure to check the "Treat
returned strings as tagged text" box.

* Edit the text of the frame on the Body page to include the rule
variable.  Set the point size of the variable to 1.

* Set the Overflow options for the Body page to overflow to your
Overflow page (in the "New Left Page" drop list).  Leave "New Right
Page" as "(None)" and set the add page mode to "As Few Added Pages As
Possible."

Here is an example of the kind of rule you need:

    // MODIFY THESE TO MATCH YOUR DATA
    var PDFResourceFile = "myfile.pdf";
    var FirstPageNumber = Int(Field("firstpagenumber"));
    var FirstPageCount = Int(Field("firstrepeatcount"));
    var SecondPageNumber = Int(Field("secondpagenumber"));
    var SecondPageCount = Int(Field("secondpagecount"));

    var result = "";
    var pdf = new FusionProResource(PDFResourceFile, "graphic");

    pdf.pagenumber = FirstPageNumber;
    for (var i = 1; i <= FirstPageCount; i++)
      result += pdf.content + "\n";

    pdf.pagenumber = SecondPageNumber;
    for (var i = 1; i <= SecondPageCount; i++)
      result += pdf.content + "\n";
      
    return result;

This assumes that you have data fields specifying the page numbers and
repeat counts for each.  You may have to play around a bit with the size
of the frames, but this should work.

Dan


+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
FusionPro 5.0 Now Available!


Variable text on a curve and soft drop-shadows for variable text


LIMITED TIME upgrade offer of $299 per license for current customers:
http://fusionpro.printable.com/store/upgrade

New licenses available for $599 each at:
http://fusionpro.printable.com/store/

All FusionPro 5.0 customers to receive FusionPro 5.1 with
Adobe Acrobat 8 and InDesign CS3 support when released for FREE.
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
--
Users of FusionPro Desktop have unlimited free email support. Contact Printable 
Support at [EMAIL PROTECTED]
--
View FusionPro Knowledge Base, FusionPro Samples at
www.printable.com/vdp/desktop.htm

--
You are currently subscribed to fusionpro as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
--


--
Note:  All e-mail sent to or from this address will be received or otherwise 
recorded by the e-mail recipients of this forum. It is subject to archival, 
monitoring or review by, and/or disclosure to someone other than the recipient. 
Our privacy policy is posted on www.printplanet.com
--

Reply via email to