Skip to Content
author's profile photo Former Member
Former Member

Skipping pages on SAPSCRIPT

Greetings all,

I have the following situation:

I have a SAPSCRIPT with the following page flow:

HEADER1->HEADER2

HEADER2->HEADER3

HEADER3->FIRST

FIRST->NEXT

NEXT->NEXT

Header1, Header2 and Header3 Pages are Terms and Condition, however they can't be shown when a certain variable has value '5', so i want to skip then, if condition is true.

What i was trying to do was:

(Inside HEADER1)

IF &variable& = '5'.

&NEXTPAGE& = 4 (4 = FIRST PAGE)

NEW-PAGE

ENDIF.

But that didn't give me any results,

PS: The printing program is Standard, so all i can change is inside the ZSAPSCRIPT.

Thank you all for your attention,

Best Regards,

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Sep 03, 2013 at 05:36 PM

    Hi Jonathan.

    When filling the output_parameters, try to set the tdpageslct = '4-'. It will begin the print from page 4.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Thank you very much Fabiano,

      I was able to implement an enhancement point on the printing program, that would allow me to change the initial page if my condition was true,

      For the record: To call a SAPSCRIPT Form, you must call function OPEN_FORM which has a parameter called OPTIONS of Structure ITCPO, so all i had to do was an enhancement to change the field TDPAGESLCT to 4, if my condition was true.

      Thank you for your attention,

      Best regards,

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.