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

how to delete an element in the main window at end of the main window.?

Hi friends,

I need to delete underline only before main window ends in a page.

I am calling 'Underline' element in mainwindow after every loop operation using 'write form' FM.

After displaying certain data the underline element is called and lines are displayed.

Now i dont want to print the underline at the end of the window in that particular page.

I just need a statement which will satisfy this condition.

Hope you guys got my question...

Regards,

Navaneeth.

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Sep 22, 2009 at 09:05 AM

    HI,

    I think you can use subroutines for the same.

    Check the condition total number of pages in the script and use a perform statement and set a flag inside the driver program. Now call the element in the driver program using that flag variable.

    see the below code

    /: PERFORM ABC IN PROGRAM ZABC USING &SAPSCRIPT-FORMPAGES(C)&
    /: ENDFORM

    In the driver program define the form and check the formpages if it is greater than 1 then call the function module write_form using the underline element.

    In driver program.

    if sapscript-formpages > 1. " write this inside the form endform using the itcsy structure
    flag = 'X'.
    endif.
    if flag = 'X'.
    call function 'WRITE_FORM'.
    endif.

    This is one possible way as i see.

    check the link for subroutines in scripts

    [Subroutines in SAPScripts|http://help.sap.com/saphelp_40b/helpdata/en/d1/803279454211d189710000e8322d00/content.htm]

    Regards

    Sarves

    Edited by: Sarves Sombhatla on Sep 22, 2009 2:35 PM

    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.