Jump to content

Need a rule to output "TEXT" on a imposed template every 50 records.


Recommended Posts

Running a non-variable page booklet. I need to place a barcode and some text every X number of pages. In this case its 50.

 

With the scanner turned on i can turn off double detect and some other features that slow down collating. If it doesn't see the mark on the 50th page it diverts the collation to the end of the line without finishing.

 

if this is a bad explaination lets make it simple. I am making pads in 50's, and i want to print "END_PAD" on the last page of every 50th page.

I have tired it with a if or statement but i think I need the function to start page count - since its every 50 imposed pages not 50 records

Link to comment
Share on other sites

It's hard to answer questions like this in the abstract, without seeing the job. But I assume that you mean you want want the barcode on the 50th imposed sheet, not on the imposed sheet containing the 50th page. So you probably want a rule something like this:

if (FusionPro.Composition.impositionSheetNumber % 50)
   return "";
//else
return "some text" + '<f name="IDAutomationC128L">' + TaggedTextFromRaw(Make128Barcode("some data"));

And you probably want to put that rule into a text box on the imposition sheet background.

Link to comment
Share on other sites

what you posted didnt work...

just need it to output a count 1 to X every 50 imposed pages.

 

and can i copy into a blank rule? or does it need to be a callback?

I can't offer any more specific suggestions without seeing the job files. Can you post the collected job? Also, I need to know, at the very least, the version of FusionPro you're running.

Link to comment
Share on other sites

Sorry...

latest version of FP 9.3.9

Acrobat X

 

attached is the job..

 

i got the code working on the impose, just not ever 50 imposed page.

I would like it to be on the 50th page, so the next page start a new pad.

 

If coding every 1st, 51, 101 etc is easier then that will work too...

 

Tried your way " % 50" and that didnt work, tried "==" to force to the right place and that works but not right.

TMC_Produce-PROOF-3.zip

Link to comment
Share on other sites

I changed the first line of your "ENDOFPADS" rule to be exactly the same as the first line of the rule I suggested earlier, so that the rule now looks like this:

if (FusionPro.Composition.impositionSheetNumber % 50)
 return " ";
//else
return Rule("PADCOUNT");

Then I composed, and in the output PDF, output pages (imposed sheets) 50 and 100 had the corresponding numbers at the bottom, and other output pages (sheets) didn't. To me, that meets the stated requirement of "Need a rule to output TEXT on a imposed template every 50 records", although it's really every 50 sheets.

 

If that's not the desired result, then please explain exactly what result you do want, and specifically how it's different from the result I got. A mock-up of the desired output may be worth a thousand words.

Link to comment
Share on other sites

Yes it works, but it outputs the imposition page count on the page instead of the counting each 50 =1

 

so on pg 50 should output 1

on pg 100 should output 2

so on pg 150 should output 3

Edited by methogod
Link to comment
Share on other sites

Yes it works, but it outputs the imposition page count on the page instead of the counting each 50 =1

 

so on pg 50 should output 1

on pg 100 should output 2

so on pg 150 should output 3

Okay, I see. That's a much better description of the requirement than what was in your first post, and also better than your responses that what I posted "didn't work," even though my initial reply did do what was described, or at least what I interpreted from your initial description, which mentioned "a barcode and some text" and "END_PAD", which was actually completely different from what you're asking for now.

 

Anyway, just change the PADCOUNT rule to this:

return FusionPro.Composition.impositionSheetNumber / 50;

Or, putting the two rules together:

if (FusionPro.Composition.impositionSheetNumber % 50)
   return "";
//else
return FusionPro.Composition.impositionSheetNumber / 50;

Or, slightly more succinctly:

return (FusionPro.Composition.impositionSheetNumber % 50) ? "" : FusionPro.Composition.impositionSheetNumber / 50;

Or:

var num = FusionPro.Composition.impositionSheetNumber;
return (num % 50) ? "" : num / 50;

Edited by Dan Korn
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...