dreimer Posted September 9, 2021 Share Posted September 9, 2021 So I have a multipage PDF and I want to compose each in a 6-up imposition and repeat that 5 time for each page consecutively. I don't have a data source. I am using a OnRecordStart rule of FusionPro.Composition.repeatRecordCount = 5; This does the repeating, but it does all pages and then repeats the whole set 4 more times. I am trying to get 1,1,1,1,1,2,2,2,2,2,etc But I am getting 1,2,3,4,5,1,2,3,4,5. Is there a way to accomplish what I am trying. Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted September 13, 2021 Share Posted September 13, 2021 The repeat record system is set up to repeat the entire multi-page record, not to repeat each page separately or collate the pages. But it is possible to get the output you want. Here's one way: var numPagesInTemplate = 5; // <- set this to the number of Body pages in the job var numRepeats = 5; // <- set this to the number of times you want to repeat each page FusionPro.Composition.repeatRecordCount = numRepeats * numPagesInTemplate; var pageToUse = Math.floor((FusionPro.Composition.repeatRecordNumber - 1) / numPagesInTemplate) + 1; for (var i = 1; i <= numPagesInTemplate; i++) FusionPro.Composition.SetBodyPageUsage(i, pageToUse == i); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.