Skip to Content
avatar image
Former Member

SapScript - Print Total value in the bottom of main window

I will explain my problem as follows for your better clarity. :)


Requirement -

I need to print the total value in the bottom of the main window. (if lines prints on multiple pages, total value should display at last page)

Problem -

when it prints only on one page and line items print close to the end of the main window, total value disappear from the bottom. It doesn't move to the next page.(pls refer the screenshot)


Logic of the smartfrom -

/E LAST
/: BOTTOM
/: INCLUDE 'ZTERMS' OBJECT TEXT ID ST PARAGRAPH AL
SS ,,<B>FINAL AMOUNT,,&KOMK-WAERK&,,&KOMK-FKWRT(C16.2)&</>
/: ENDBOTTOM


Logic of the driver program -

*) Call 'WRITE_FORM' with element = 'LAST' before it calls 'CLOSE_FORM' function module.

Assumptions -
*) Cant use PROTECT command with the BOTTOM command.
*) Cant use &SAPSCRIPT-FORMPAGES&

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Oct 03, 2017 at 01:11 AM

    Found the same question without answer :(

    https://archive.sap.com/discussions/thread/2008206

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 05, 2017 at 10:51 PM

    Jelena, Thanks for your reply. I have already used 'BOTTOM' command as it explained, but it works fine except the situation which I have described in my question. (If output has only one page and line items end closer to end of the main window). Will SAP supports for Z sapscript developments?

    Yes, I agree, frustrating to work with old technologies :)

    Add comment
    10|10000 characters needed characters exceeded

  • Oct 05, 2017 at 04:35 PM

    There is a similar question and it is answered: https://archive.sap.com/discussions/thread/1263601

    It says the text needs to be in MAIN wrapped in BOTTOM. If this still doesn't work then I'd suggest to reach to SAP Support.

    Also Sapscript <> Smartform and at this stage I'd really recommend trying to migrate from Sapscript to Smartforms or better Adobe Forms. There won't be any Sapscripts in S/4HANA (finally!).

    Add comment
    10|10000 characters needed characters exceeded