cancel
Showing results for 
Search instead for 
Did you mean: 

SAP script addition of last page without changing print program not working

Former Member
0 Kudos

Hi techies,

I have an existing script with two pages 'first', 'next' and i am adding 'last' page to it consisting of a letter in the content.

I have not changed anything in the print program for this.

In page attributes this is the sequence of next page,

FIRST -> NEXT

NEXT-> NEXT

LAST->LAST,

when i give this  way i get  "Output is continuous or contains too many pages >6" error as the last page is called again and again.

FIRST -> NEXT

NEXT-> NEXT

LAST->Blank,

with this format i get "control form invalid , start_form missing error"

i tried giving

/: IF &NEXTPAGE& = 0
/: NEW-PAGE LAST
/:ENDIF

But nextpage value is never zero.It keeps on incrementing for everypage only.

Please help on this.

Accepted Solutions (1)

Accepted Solutions (1)

eduardo_hinojosa
Active Contributor
0 Kudos

Hi

Control it with the parameters

/: IF &SAPSCRIPT-FORMPAGES& =&PAGE&

* here write it with the proper format.

/: ENDIF

I hope this helps you

Regards

Eduardo

Former Member
0 Kudos

Thanks

IF &PAGE& GT &NEXTPAGE&

NEW-PAGE LAST

ENDIF

Now i need to stop printing the main window contents in last page alone .

Is there any system variable for finding the current page name,

so that i could keep a check on pagename to restrict it from getting printed in last page.

I tried  ITCTH-TDPAGE, ITCTG-TDPAGE, SY_PAGENAME,

SFSY-PAGENAME . nothing worked

 

Answers (0)