This website is not affiliated with, sponsored by, or approved by SAP AG.

SapScript : print a window only on the last page

Development SAPscript/ Smartforms

Moderators: Snowy, thx4allthefish, YuriT, Gothmog

SapScript : print a window only on the last page

Postby trmelara » Thu Aug 06, 2009 8:36 am

I need to fix a problem in a Sapscript form that has the following pages:

Page Description NextPage Mode No.type
BACK T&C Page NEXT HOLD ARABIC
FIRST First Page BACK INC ARABIC
LAST Last Page of PO HOLD ARABIC
NEXT Subsequent page BACK INC ARABIC

For both Pages BACK and LAST:

Window Description
T_C_FTTR FOOTER FOR THE TERMS & C S
T_C_FULL FULL PAGE FOR THE TERMS & C => Terms and Conditions (Full page)
T_C_LEFT LEFT SIDE FOR THE TERMS & C
T_C_RIGH RIGHT SIDE FOR THE TERMS & C
T_C_TITL TITLE FOR THE TERMS AND C S

This Sapscript should print Terms and Conditions ONLY in the LAST page.

I tried the following codes inside the window T_C_FULL but it did not work:

/: IF &NEXTPAGE& = '0'
Terms and Conditions
/: ENDIF

/: IF &PAGE(3ZC)& = &SAPSCRIPT-FORMPAGES(3ZC)&
Terms and Conditions
/: ENDIF

Obs: Inside the MAIN window, in "LAST" element, there is the code "NEW-PAGE LAST" into "protected" block.

After lot of tests, or the Terms and Conditions is printed in every "back/last" pages or any of them.....

Any help?????
Thank you.
Trmelara
trmelara
 
Posts: 6
Joined: Thu Aug 06, 2009 8:08 am

Re: SapScript : print a window only on the last page

Postby new2sapfans » Mon Aug 10, 2009 7:53 am

I believe duplex printing of T&C is best achieved by the "print mode" setting on a page
as per the following specifications (see 3rd post in the chain of topics).
http://www.sapfans.com/forums/viewtopic.php?t=159459

FIRST and NEXT page are set to duplex mode.
The same T&C are maintained in 2 pages - one a simplex and another a duplex.
The sequence of pages is decided by the "next page" setting per page, and so is the page increment.
FIRST and NEXT page keep calling the duplex T&C page as long as there is data to be printed in the MAIN window.
At the end of the MAIN window, the simplex T&C page is called which terminates the cycle of duplex calls.
new2sapfans
 
Posts: 71
Joined: Thu Jan 01, 2009 11:01 am

Re: SapScript : print a window only on the last page

Postby trmelara » Mon Aug 10, 2009 10:51 am

Thank you!!!!!
trmelara
 
Posts: 6
Joined: Thu Aug 06, 2009 8:08 am


Return to SAPscript/Smartforms

Who is online

Users browsing this forum: No registered users and 4 guests





loading...


This website is not affiliated with, sponsored by, or approved by SAP AG.