on 06-08-2014 4:16 AM
Hi gurus,
I've created a form that needs to be printed in two copies. I want the header data (a simple text field) to be different each time. I wanted to see if this is possible with the following restrictions:
I was wondering if this can be done thru scripting, or that there's a variable that may tell how many copies have already been printed so an Alternative can be used...
Cheers,
Marc
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Marc,
Yes, you can do it. The below method will not call the adobe form FM twice and you don't even need to create a new master page.
If the value of header field in Master page changes each time, You need to JavaScript for this.
So you will be having some dynamic data in design view based on which the header will be changing. So fill the value of header in the design view. And write the JavasScript code on the Header Text field of Master page in Ready Layout event as below.
var currpage = xfa.layout.page(this);
var fields = 0;
fields = xfa.layout.pageContent(currpage-1, "field", 0);
for ( i=0; i<= fields.length-1; i++ )
{
if ( fields.item(i).name == "HEADER" )
{
this.rawValue = fields.item(i).rawValue;
}
}
Here HEADER is the field in the design view which contains the value of Header. So whenever the same master page is triggered each time, the Header in the Master page is filled using this HEADER field from design view.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.