Jump to content

Recommended Posts

Posted (edited)

I have a 2 page 8.5 x 11 PDF and when I compose with a simple 2up imposition I get a 11 x 17 with Record 1 on the left and Record 2 on the right. Is there a way to get Record 1 Page 1 on the left and Record 1 Page 2 on the right? All on the same side? FP Imposer it seems to be record driven and each page creates a new page. Is there a way to make it page driven and when it runs out of pages it goes to the next record?

 

Is FP Imposer the answer or is there something I can create in FusionPro using Javascript?

Edited by Sdawson
Posted
Well what I was going to try won't work anyway. Why not just have your FP template be 17X11 and place your two 8.5 X 11 pages side by side since they are all two pages?
Posted

That is my current process. I am wondering if there is another way to do it using FP Imposer. I would like to take the 2 page PDF I receive from the client, then connect to the data, import my variable fields, and grab my imposition file then compose. Instead of receiving a file from the client and making it into a 17x11. I currently make page 1 and page 2 a resource and just add them to my 17x11 template.

 

Thank you for your help dreimer.

Posted
I am trying to do something similar and thought Fusion Pro could do it. I have a 30 page PDF of one-ups that is ready to go and I just want to impose it to 15 per imposed sheet and I can't seem to do it.
Posted

Since your document is 2 pages it wants to impose these as a collated set. You can get around this by repeating each record twice (once for each page) and turning off the 2nd page the first time and the 1st page the second time. To do this you'll just need to add this to an OnRecordStart callback rule:

FusionPro.Composition.repeatRecordCount = 2;
FusionPro.Composition.SetBodyPageUsage(1, FusionPro.Composition.repeatRecordNumber == 1);
FusionPro.Composition.SetBodyPageUsage(2, FusionPro.Composition.repeatRecordNumber == 2);

Posted

Step, I tried your rule for my scenario since no one else has responded to what I was trying. So my code looks like this to get my 26 page PDF imposed using my imposition file.

 

FusionPro.Composition.repeatRecordCount = 26;
FusionPro.Composition.SetBodyPageUsage(1, FusionPro.Composition.repeatRecordNumber == 1);
FusionPro.Composition.SetBodyPageUsage(2, FusionPro.Composition.repeatRecordNumber == 2);
FusionPro.Composition.SetBodyPageUsage(3, FusionPro.Composition.repeatRecordNumber == 3);
FusionPro.Composition.SetBodyPageUsage(4, FusionPro.Composition.repeatRecordNumber == 4);
FusionPro.Composition.SetBodyPageUsage(5, FusionPro.Composition.repeatRecordNumber == 5);
FusionPro.Composition.SetBodyPageUsage(6, FusionPro.Composition.repeatRecordNumber == 6);
FusionPro.Composition.SetBodyPageUsage(7, FusionPro.Composition.repeatRecordNumber == 7);
FusionPro.Composition.SetBodyPageUsage(8, FusionPro.Composition.repeatRecordNumber == 8);
FusionPro.Composition.SetBodyPageUsage(9, FusionPro.Composition.repeatRecordNumber == 9);
FusionPro.Composition.SetBodyPageUsage(10, FusionPro.Composition.repeatRecordNumber == 10);
FusionPro.Composition.SetBodyPageUsage(11, FusionPro.Composition.repeatRecordNumber == 11);
FusionPro.Composition.SetBodyPageUsage(12, FusionPro.Composition.repeatRecordNumber == 12);
FusionPro.Composition.SetBodyPageUsage(13, FusionPro.Composition.repeatRecordNumber == 13);
FusionPro.Composition.SetBodyPageUsage(14, FusionPro.Composition.repeatRecordNumber == 14);
FusionPro.Composition.SetBodyPageUsage(15, FusionPro.Composition.repeatRecordNumber == 15);
FusionPro.Composition.SetBodyPageUsage(16, FusionPro.Composition.repeatRecordNumber == 16);
FusionPro.Composition.SetBodyPageUsage(17, FusionPro.Composition.repeatRecordNumber == 17);
FusionPro.Composition.SetBodyPageUsage(18, FusionPro.Composition.repeatRecordNumber == 18);
FusionPro.Composition.SetBodyPageUsage(19, FusionPro.Composition.repeatRecordNumber == 19);
FusionPro.Composition.SetBodyPageUsage(20, FusionPro.Composition.repeatRecordNumber == 20);
FusionPro.Composition.SetBodyPageUsage(21, FusionPro.Composition.repeatRecordNumber == 21);
FusionPro.Composition.SetBodyPageUsage(22, FusionPro.Composition.repeatRecordNumber == 22);
FusionPro.Composition.SetBodyPageUsage(23, FusionPro.Composition.repeatRecordNumber == 23);
FusionPro.Composition.SetBodyPageUsage(24, FusionPro.Composition.repeatRecordNumber == 24);
FusionPro.Composition.SetBodyPageUsage(25, FusionPro.Composition.repeatRecordNumber == 25);
FusionPro.Composition.SetBodyPageUsage(26, FusionPro.Composition.repeatRecordNumber == 26);

 

Anyone know if there is a way to write a loop for each page in the PDF template instead of having to add a line in the rule for each page? TIA

Posted

You could set all of the pages to "unused" and change the code to:

FusionPro.Composition.repeatRecordCount = 26;
FusionPro.Composition.SetBodyPageUsage(FusionPro.Composition.repeatRecordNumber, true);

Posted

Thanks step,

 

That works good to make a simpler rule but then I would have to go through and change all the pages to unused. Was hoping for something easier. May use this kind of thing for hundreds of pages. May have to look into another program to accomplish this.

Posted (edited)

Would a JavaScript For Loop work?

 

This has not been tested. Not sure if it works or is allowed here.

 

var p = 26//Set your page count

FusionPro.Composition.repeatRecordCount = p;

var i;
for (i = 0; i < p+1; i++) {
   FusionPro.Composition.SetBodyPageUsage(i, FusionPro.Composition.repeatRecordNumber == i);
}

Edited by David Miller
Posted

^^No sale. It creates a full imposed sheet for each page in the template.

 

I get this error:

OnRecordStart, line 7: Error: In SetBodyPageUsage(), invalid page number 0

Composing record #1, input record 1, repeat 1 of 26

Sheet #1, record #1

Posted (edited)

Should have tested before posting. My mistake. The loop started at 0. Should have started it at 1.

 

Via the OnRecordStart Callback Rule:

var p = 26//Set your page count

FusionPro.Composition.repeatRecordCount = p;

var i;
for (i = [color="Red"]1[/color]; i < p+1; i++) {
   FusionPro.Composition.SetBodyPageUsage(i, FusionPro.Composition.repeatRecordNumber == i);
}

 

The page number should never be set to 0 (zero). Edit is in red. Give it a try.

 

Tested with the template files from the original post. Unless I missed something, the original FPI file should be set to Simplex instead of Duplex Perfected. It is important to make this change.

Edited by David Miller
Typo

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...