Report in Role Tailored: can return the number of pages?

Hello everybody!

We are designing 2 different reports to use in the role tailored version, so we have created a Layout in Visual studio.

We have a third report without layout because it’s only a process (called from role tailored too). We’re going to call the first two reports from the third report.
We need to know the number of pages of the first report to pass the number of pages + 1 to the second report (to use as the first page)

How can we obtain the number of pages of a report printed in Role Tailored?

The classic version has the [CurrPageNo] := PAGENO([NewPageNo]) function, but we are in role tailored and layout design.

Please, can anybody help us?
Thanks a lot!!