thanks for the quick respond. basically i did what you said and i also looked at the documentation on XML publisher. however i still couldn't get this page number to work.
so to review i used Insert >> page number inside my table
so i have like this f 1 f which are <?for-each@section:G_HEADERS?>1 <?end for-each?> where 1 is the page number field. however this got rid of the page number all together. nothing get printed for page number at all.
i thought its because i have it within my table. so I put the same thing on the header and that didn't work either.
the only thing i thought of was editing the page field itself. which that didn't go well.
do you have any idea?
create a sample report as follows.
Use the Ms word , option of putting the page number in the MS word page header.
then in the page
create a simple xml like this,
<name> page 1 </name>
<name> page 2 </name>
<name> page 3 </name>
<name> page 4 </name>
<name> page 5 </name>
use this syntax
merge the rtf with the xml,
you can notice that,
the report contains, 5 pages, with the all pages having the page number as 1.
How does that happen ?
for-each@section:root/page , this syntax is going to reset the page every time it find a new root/page node.
in this example we had only one page in the report,
thats why we had the page 1 all the five pages
other wise we will have different set of page numbers for each G_HEADERS.
<?for-each@section:SOME_ELEMENT?> will reset the headers and footers of the new occurence of SOME_ELEMENT. This means all elements in the headers and footers will now be in context of the new SOME_ELEMENT, however it does also reset the page numbering as long as it is not within the <?for-each@section:SOME_ELEMENT?> group.
Bascially all this tag is doing is inserting a section break (new page) after every occurence of SOME_ELEMENT.
I have successfully used this technique for approximately 90% of the templates I have developed and have had no issues with page numbers being reset. I am aware that there was an issue with page numbering is earlier versions of XMLP, so I would recommend that you ensure you are either using XMLP 5.6.3 with EBS, or 10.1.3.3.x for BI Publisher.
If you are still having issues, please let me know and I will send you an example of it working.
I have succesfully used the "for-each@section:G_group" and "end it with end for-each or end end for-each@section:G_group" and I get page number properly and also page number resets for each element as per@section:g_group but there in one Problem /......After each element the page number resets eg: 1,2,1,2,3,1,2,3,4,1,2..but there is an empty page after each element for eg; after each invoice there is a blank page or eg: 1,2,blankpage,1,2,3,blank page,1,2,3,4,blank page....etc...
How do I get rid of the extra blank page?
Using the @section context with the for-each:group should have reset paging and should have automatcally created a new page at the end of each group. It was not working for me at first. Even had to make use of split-at-page-breaks to force a new page and initial-page-number:number to hopefuly force a page reset.
Not until I have taken the for-all markers outside of the table did it all start working. No need to use split-at-page-breaks and initial-page-number.
A simple for-each@section handled new-paging and page reset.
I am generating 6 copies of my invoice print report in XMl publisher. Generating successfully, now i need to give a number to a copy of invoice. Like first copy will be copy no. 1, it could be possible that one copy of invoice will have multiple pages. And then on the basis of copy no, i have to change the copy heading like if copy no 1 then 'Original', copy no 2 then 'Duplicate' like this. Please help. It is urgent.
Thnks in advance.
Edited by: user12209274 on Jul 12, 2012 5:08 AM
<?for-each:ORDER?> in the RTF produces a beautiful 44-page file, but the page number doesn't reset for each ORDER.
<?for-each@section:ORDER?> produces a 36-page document, but all the pages are blank (except for the odd-numbered pages which show boiler-plate terms and conditions.
I'm looking for the correct incantation to produce the 44-page document with correct page numbering resets with each new invoice.
<?for-each@section:ORDER?> is it first loop? Because it should be first loop and if u r using any split by page breaks then remove that. and go to insert menu and page numbers current position and select x of y then u will get correct output.
I hope this will help u.....