Page No. in Smart forms
I want to print some 30 records in smart forms with the key item as invoice number, in this for a particular invoice number say '4' and it has 20 item data, all these item data cannot be printed in a single page so they extend to second page and third page, now i want the page no for this to be printed as
Page <current page> of <total page>. (for the respective invoice number)
Page 1 of 3 (in first page of the invoice number 4)
Page 2 of 3 (in second page of the invoice number 4)
Page 3 of 3 ( in third page of the invoice number 4)
and when the next invoice no say '5' is to be printed this has to be cleared and must be printed again based on the item data of that invoice.
please help me in this.