I have also tried showing the page number on the signature page template but though it shows on that page it does not apply to the rest of the document and the page numbering is wrong (it always says 1 of 1 even if there are 15 pages before it in the final document).
I would be grateful for any help,
I have the same needs and I would like to know if you found the solution. If yes, can you please share the created code?
thanks in advance,
You could also use the 'addWaterMarkFromText' method.
There are examples of how to add fields, format Fields, in the Adobe Acrobat JS API Reference that covers creating scripts, adding fields, accessing page numbers, setting values, setting field formats by script.