I want to add page number in my custom page footer. But I found the page number is different for each page. So how can I create the template for footer?
The total number of pages is not known during the generation of the report so you cannot get to that but you can get to the current physical and/or logical page number. You can look at the help for the PhysicalPageNumber for an example.
I think it is not a problem to know total number of pages during report generation. Which property of Report will store the value?
Do you know if this feature of adding current page and total page count in the footer have been added to the Report? I see that this post is over 11 years old.
You can submit suggestions here and they will be considered for future versions of the product. You can also watch for the CTP of the NetAdvantange Reporting.
Could you help me to add a requirment for this? I can't use the estimated page number. Thanks.
There is no property of the Report that knows or stores the page count. You could hook the PrintProgress event which occurs as each page is printed/exported but again that won't help you put the page count into the report since the pages will have been generated already. If you're printing a grid then you may be able to hook the PaginationStarted of that section and look at the section's VisualPaginator's EstimatedPageCount. Its an estimate but it may get you close to what you want. You would then probably have to set your own attached property on the section to store that value and then in the header/footer of the pagepresenter bind to the reportpagepresenter->section->yourattachedpropertywithestimatedcount.