How to dynamically show field in RTF template based on the position of another field

5.3k views Asked by At

We have a requirement in XML Publisher reports by which the RTF template have some field at the bottom of the page. The position of the field from the bottom is based on many attributes(word counts of all the above fields)

The field will be shown in first page or on the second page if the template cant accommodate the field in the first page.

When the field is too big it will move to second page leaving behind large amount of blank space in the first page. (we have unchecked Allow row to break across pages as this field shouldn't split into two pages)

The requirement is if this field is shown on the second page we need to dynamically show some value(like the value will be shown in the second page) in the first page.

Is there anyway we can achieve this ?

1

There are 1 answers

2
Ranjith R On

I think you will have to put an if condition, to check the length of the data in the field you are printing, and conditionally print the hard coded text as the last text on page1. You will have to go by trial and error to find the right length where BIP decides to push to page2.

<?xdofx:length(char)?> returns the length of char.