cancel
Showing results for 
Search instead for 
Did you mean: 

Page No. in Smart forms

Former Member
0 Kudos

Hi,

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.

thanks,

Sarath.C

Accepted Solutions (0)

Answers (3)

Answers (3)

sharadendu_agrawal
Active Participant
0 Kudos

U can take the help of some flags.. ie like resetting the flags when one particular invoice gets printed. If the flag is restting then u can clear the values of the sfsy-formpages and sfsy-page fields and thus u can get the desired output.

Reward if helpful.

Former Member
0 Kudos

I dont now if this can be done but a little easier approach would be ibstead of passing all the Invoice numbers at the same time, u can call your FM inside a loop for each Invoice....

This would solve the purpose..

Thanks.

Former Member
0 Kudos

HI utsha,

Thanks for ur suggestion let me try what you said.

Thanks,

Sarath.C

Former Member
0 Kudos

Hi Sarath,

You can use &SFSY-PAGE& of &SFSY-FORMPAGES& . It will automatically incement the page number and if you print for next document it will automatically cleared.

Thanks,

Madhu.

Former Member
0 Kudos

Hi madhu,

I used that option but its printing like

Page 1 of 30 (for total of 30 records). But I want the page no to printed for each header item .