Jump to content

Repeat Same Page With Unique Numbering


MIB

Recommended Posts

Hi,

 

I've searched the forums and still cannot find a solution or found a way to get it working.

 

Scenario

I have a 2 page PDF and I want to output 100 copies with each copy on the front page displaying a unique number ie. 1 to 100.

 

I know I can do this very easily by connecting to a database, but there must be a simpler way to do this without creating a database each time as you can do this in PrintShop Mail without a database.

 

Any help with this would be greatly appreciated for a Javascript newbie.

 

Thanks in Advance!

Link to comment
Share on other sites

When defining your data source:

"Specify a data source definition" Click Next

"None" Click Next

Click Finish

 

Create an OnJobStart callback rule and put this in it:

FusionPro.Composition.composeAllRecords = false;
FusionPro.Composition.endRecordNumber = 100; // number of copies

 

Create a blank text rule that will return the sequence number and then put it in a text frame on the first page:

return FormatNumber("000",CurrentRecordNumber());

Link to comment
Share on other sites

  • 1 month later...

Having had time to look at this again, there is another simpler way than the first solution, which includes padding if you want it or not.

 

Create/Select the "Sequential Numbering Rule" rule via Rules with the padding you want. Insert that rule into the text frame and then compose. Specify your output file and the record range via the Input tab.

Link to comment
Share on other sites

  • 1 month later...

Hi,

How can you take it a step further and do this with the user inputting a start number and end number in marcom, and then having the composition generate the number of pages with that corresponding number printed on the corresponding page dynamically?

 

ie start number 35

end number 62

 

 

Input is appreciated!

Link to comment
Share on other sites

Hi,

How can you take it a step further and do this with the user inputting a start number and end number in marcom, and then having the composition generate the number of pages with that corresponding number printed on the corresponding page dynamically?

 

ie start number 35

end number 62

 

 

Input is appreciated!

This is now a MarcomCentral question, which should really be asked in the MarcomCentral forum. I'm not quite sure how the numbers on the MarcomCentral input form would be applied to the composition.

 

If the numbers are field values, then you can't use them in OnJobStart, as they are specific to a record of data. Although you might be able to do something like this in OnRecordStart:

FusionPro.Composition.repeatRecordCount = Int(Field("End Number") - Int(Field("Start Number")) + 1;

Then you could do this in another rule to get the sequence number:

return FormatNumber("000", FusionPro.Composition.repeatRecordNumber + Int(Field("Start Number") - 1);

However, I'm not sure that MarcomCentral will let you do a repeat like this. I think it has some other mechanism to do this kind of thing. That's why I would ask in the MarcomCentral forum.

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