on 09-13-2011 2:34 PM
Hi All,
I have a simple problem. I have a master page with some header information almost all of which is fixed text. One piece of dynamic data does exist on the master page - the document number.
I've created a field in the master page which is bound to $.Agreement[].Customer[].DocumentNumber.
When the PDF is rendered in the browser, the first page has an document number as part of the header provided by the master page.
All subsequent pages have a header with the correct fixed text but the document number is blank. More strangely, when I save the PDF locally, the first document number is missing, but the one on page 2 is there.
Can anyone help populate all document numbers on all pages?
Cheers
Richard
Dynamic content on master page is always a problem. Copy the field in design view and using scripting copy the value into the master page. This way it works. Please let me know, if you need some scripting.
Thanks,
Rakesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have resolved the issue I think.
I have added a hidden field on the main content and in the initialise script for the document number, I have filled the master page field from the main content.
This seems to run for each new page and fills correctly.
Cheers
Richard
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Richard,
We have a similar problem. Could you explain (incl. scripting) how you solved the issue. I have a field on the master page which should show the current profit center.
I have a table with postings sorted by profit center. Before change of profit center, I've implemented a condition page break based on profit center. That works fine.
On the master page I would like to show the current profit center based on dynamic data from table. One the first page it works but on the subsequent pages, it doesn't (i get the profit center from first page).
Thanks for any ideas,
Marcel
hello,
Please add the current profit center field in the table where you are dynamically displaying the field(In design view). Now populate that field into master page using this script.
var fields = xfa.layout.pageContent(xfa.layout.page(this)-1, "field", 0);
var altext;
for (var i=0; i <= fields.length-1; i++)
{
if (fields.item(i).name == "CURRENTPROFITCENTER")
{
alttext = fields.item(i).rawValue;
}
if (fields.item(i).name == "PROFITCENTER")
{
fields.item(i).rawValue = alttext;
}
}
Make sure to have variable names and field names as unique in entire form.
Thanks,
Rakesh.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
7 | |
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.