cancel
Showing results for 
Search instead for 
Did you mean: 

script

Former Member
0 Kudos

hi,

i created a mail merge program in sapscript.my problem is after the last record one more page displays with blank main window with header and footer.plz correct me.

code :

😕 dear &itab-ename&

😕 your sal is &itab-sal&

:/new-page

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Manikandan,

Reduce the height of main window in the first page and try.

Regards,

Satish

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Manikanda,

<b>&NEXTPAGE& </b>is used to print the number of the following page. The output format is the same as with &PAGE& .

Note that on the last page of the output, in each window that is not of type MAIN, &NEXTPAGE& has the value 0.

So, have your code as below:

😕 dear &itab-ename&

😕 your sal is &itab-sal&

<b>/: IF &NEXTPAGE& IS NOT INITIAL</b>

:/new-page

<b>/: ENDIF</b>

Thanks,

Vinay