Go Back   MarcomCentral (PTI) and FusionPro User Communities > Software-Related Talk > FusionPro® VDP Creator

Notices

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old February 3rd, 2014, 01:29 AM
MIB MIB is offline
Junior Community Member
 
Join Date: Apr 2013
Posts: 20
Default Repeat Same Page With Unique Numbering

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!
Reply With Quote
  #2  
Old February 3rd, 2014, 06:12 AM
step's Avatar
step step is offline
Senior Contributor
 
Join Date: Jan 2010
Location: Charlotte, NC
Posts: 955
Default Re: Repeat Same Page With Unique Numbering

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:
Code:
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:
Code:
return FormatNumber("000",CurrentRecordNumber());
__________________
Ste Pennell
FusionPro VDP Creator 9.3.15
Adobe Acrobat X 10.1.1
Mac OS X 10.12

LinkedIn
Reply With Quote
  #3  
Old February 3rd, 2014, 07:08 AM
MIB MIB is offline
Junior Community Member
 
Join Date: Apr 2013
Posts: 20
Default Re: Repeat Same Page With Unique Numbering

Many thanks Step! It worked perfectly.
Reply With Quote
  #4  
Old March 21st, 2014, 01:01 PM
johnw johnw is offline
Junior Community Member
 
Join Date: Sep 2010
Location: Gastonia, NC
Posts: 28
Default Re: Repeat Same Page With Unique Numbering

I'm glad I stumbled on this. It just made a job I'm working on a lot easier. Thanks!
Reply With Quote
  #5  
Old March 21st, 2014, 02:39 PM
Dan Korn's Avatar
Dan Korn Dan Korn is offline
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,305
Default Re: Repeat Same Page With Unique Numbering

You can do this without any JavaScript rules at all, if you don't need the leading zero padding in the numbers. Just set the Record Range on the Input tab of the Composition Settings dialog, and insert the $inputrecordnumber variable in a text frame.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});
Reply With Quote
  #6  
Old March 25th, 2014, 02:49 AM
MIB MIB is offline
Junior Community Member
 
Join Date: Apr 2013
Posts: 20
Default Re: Repeat Same Page With Unique Numbering

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.
Reply With Quote
  #7  
Old May 15th, 2014, 12:39 PM
Kdeligio Kdeligio is offline
Forum n00b
 
Join Date: Mar 2012
Posts: 3
Default Re: Repeat Same Page With Unique Numbering

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!
Reply With Quote
  #8  
Old May 15th, 2014, 01:20 PM
Dan Korn's Avatar
Dan Korn Dan Korn is offline
FusionPro Senior Engineer / Forum Moderator
 
Join Date: Aug 2008
Location: Chicago, IL
Posts: 4,305
Default Re: Repeat Same Page With Unique Numbering

Quote:
Originally Posted by Kdeligio View Post
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:
Code:
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:
Code:
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.
__________________
Dan Korn
FusionPro Developer / JavaScript Guru / Forum Moderator
PTI Marketing Technologies | Printable | MarcomCentral
LinkedIn

I am a not a Support engineer, and this forum is not a substitute for Support. My participation on this forum is primarily as a fellow user (and a forum moderator). I am happy to provide help and answers to questions when I can; however, there is no guarantee that I, or anyone else on this forum, will be able to answer all questions or fix any problems. If I ask for files to clarify an issue, I might not be able to look at them personally. I am not able to answer private messages, emails, or phone calls unless they go through proper Support channels. Please direct any sales or pricing questions to your salesperson or inquiries@marcom.com.

Complex template-building questions, as well as all installation and font questions or problems, should be directed to FusionProSupport@marcom.com. Paid consulting work may be required to fulfill your template-building needs.

This is a publicly viewable forum. Please DO NOT post fonts, or other proprietary content, to this forum. Also, please DO NOT post any "live" data with real names, addresses, or any other personal, private, or confidential data.

Please include the specific versions of FusionPro, Acrobat, and your operating system in any problem reports or help requests. I recommend putting this information in your forum signature. Please also check your composition log (.msg) file for relevant error or warning messages.

Please post questions specific to the MarcomCentral Enterprise and Web-to-Print applications in the MarcomCentral forum. Click here to request access. Or contact your Business Relationship Manager (BRM/CPM) for assistance.

Please direct any questions specific to EFI's Digital StoreFront (DSF) to EFI support.

How To Ask Questions The Smart Way

The correct spellings are JavaScript, FusionPro, and MarcomCentral (each with two capital letters and no spaces). Acceptable abbreviations are JS, FP, and MC (or MCC). There is no "S" at the end of "Expression" or "Printable"! The name of the product is FusionPro, not "Fusion". "Java" is not is not the same as JavaScript.

Check out the JavaScript Guide and JavaScript Reference! FusionPro 8.0 and newer use JavaScript 1.7. Older versions use JavaScript 1.5.

return "KbwbTdsjqu!spdlt\"".replace(/./g,function(w){return String.fromCharCode(w.charCodeAt()-1)});
Reply With Quote
Reply

Tags
javascript, sequential numbering

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 11:42 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
(c) 2011, PTI Marketing Technologies™, Inc.