Jump to content

Repeat one page only


Susan

Recommended Posts

I have a 2-page PDF. Each page has different artwork but they both will use the same variable data. I need 5 copies of page 1 and 1 copy of page 2.

Can I use a OnRecordStart rule to accomplish this? I was hoping to compose a smaller vdx file by not have to use a 6-page pdf.

Link to comment
Share on other sites

  • 2 months later...
I have a similar job. I have a 100 page PDF and certain pages need to be duplicated and some just output once. For eaxmple pages 1 through 4 need one copy, 5 through 10 need 4 copies, 11 through 19 need one copy, 20 through 26 need 5 copies and so on. There is no pattern to it, it will vary. There are no text boxes or variable, just the PDF pages. Was thinking Fusion Pro could work. Can this be done?
Link to comment
Share on other sites

You could create a 100 record long input file with variable page counts for each. Create a blank PDF with a full size graphic box and name it something like MyPDFBox.

 

OnJobStart

r = CreateResource("100Page.pdf", "graphic");

 

OnRecordStart

r.pagenumber = FusionPro.Composition.inputRecordNumber;
FindGraphicFrame("MyPDFBox").SetGraphic(r);

FusionPro.Composition.repeatRecordCount = parseInt(Field("RepeatPage"));

 

I've attached a sample.

Sample.zip

Edited by ThomasLewis
Link to comment
Share on other sites

  • 2 weeks later...

Dan,

Hi Is there a way to use this to create a reciepe book? Each reciepe would start with a "Header Page" (Photo, Description, Title), Next would be ingerdients, instructions etc. This would flow from the Header Page" to an overflow page.

So far so good. I got 1 reciepe. Reciepe #2 needs to folow the same pattern.

Use the Header Page, then overflow to the overflow page; then do the same with all the reciepes, making 1 book. Can you give me some pointers?

Link to comment
Share on other sites

Dan,

Hi Is there a way to use this to create a reciepe book? Each reciepe would start with a "Header Page" (Photo, Description, Title), Next would be ingerdients, instructions etc. This would flow from the Header Page" to an overflow page.

So far so good. I got 1 reciepe. Reciepe #2 needs to folow the same pattern.

Use the Header Page, then overflow to the overflow page; then do the same with all the reciepes, making 1 book. Can you give me some pointers?

Sure. Each recipe would be one record in the input data, and would compose to one record in the output, with overflow pages as needed.

Link to comment
Share on other sites

So, in your scenario, you're clients are entering all of their recipes, descriptions, and images for the entire cookbook as one record? Do you have a sample of what the resulting data would look like?
Link to comment
Share on other sites

That wold result in a bunch of PDFs.
No, it wouldn't, unless you set the job to output each data record to its own output file.
This project has clients going on line, creating several recipes & ordering a book of their recipes.
I see no reason at all why that won't work.
Link to comment
Share on other sites

Yes Here it is

That .json file is not going to work as input data to FusionPro. You need to get the data into a flat-file format, ideally a tab-delimited file, with one record of data per line. Also, FusionPro is not going to recognize all the markup tags in there, such as <h2>.

 

You could write a JavaScript rule to load the file and pull the data out of it, and to replace the HTML-type tags with tags that FusionPro can deal with, but that's not straightforward to do. You really will be better off giving FusionPro a flat file.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...