Skip to Content

ELEMENT in SAp script


Can anyone explain me the benifits and functionality of ELEMENTS we use in SAP Scripts..?

In what situations we can set these ELEMENTS and how to deal when we set the elements kind of things.

And can we use multiple ELEMENTS in one window..? If so, please explain me how to write the code and deal in such cases.

Thanks in advance.



Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Aug 31, 2007 at 11:34 PM


    In print program you can specify when a certain element should be printed, it gives you a control on the sap script processing and therefore sap script form is more flexible and general.

    SAPscript calls the individual text components of a form text elements. To achieve good structuring and readability, you assign a fixed name to each text element in the form. The print program then uses these names to access the elements. This name applies also for translated versions of a text element, while the contents of the text elements depend on the language.

    Text elements are related to a window, that is, a print program can call for each window only those text elements that exist in this window. They are used in main and other windows.

    The variables used within '&...&' are replaced by the system at output time

    /E <element name>

    UL &fieldnam& text text

    Named element are written when driver program use




    TYPE = 'BODY'


    Unnamed element are written once in MAIN windows, and each time in other windows.

    U can use use multiple ELEMENTS in one window.



    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Aug 31, 2007 at 11:12 PM


    Elements are used to group a related information to print in the script.. You can use as many elements as you want in one window.. for example let us say i want to print

    Item Material quantity

    10 ADB 10

    20 DEF 20

    30 SDF 30


    Total 60


    Here we would be using the main window to print this data.. as we are not sure how many line items exist.

    In this main window i would delcare 3 elements header, details, total elements.

    when calling from program

    Use the WRITE_FORM AND pass the window name and element name to call the resepective window.



    Add a comment
    10|10000 characters needed characters exceeded

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.