Write_list

In a report program, I have some write statements, and then I am calling another report using submit...export list to memory and return, then calling FM write_list.
Why is the page number set to 1 for the list from memory even though I expect to see the list in the current page just as a continuation of my write statements in the report. Is there any way to write the list as the continuation instead of stating at a new page?
Thanks
Anu

Hi
After you get back the list from memory using the FM
  CALL FUNCTION 'LIST_FROM_MEMORY'
    TABLES
      listobject = i_listobject
    EXCEPTIONS
      not_found  = 1
      OTHERS     = 2.
then use FM
    CALL FUNCTION 'LIST_TO_ASCI'
      TABLES
        listasci           = i_ascii
        listobject         = i_listobject
      EXCEPTIONS
        empty_list         = 1
        list_index_invalid = 2
        OTHERS             = 3.
The table i_ascii will contain the output of the list.
Just check if you give
loop at i_ascii into wa_ascii..
write  wa_ascii.
endloop.
maybe this can solve your problem.

Similar Messages

  • Reg WRITE_LIST

    Hi All,
                  I am using the function module write_display to display the output of a report (submit used inside), though the output contains multiple pages the display only shows as 1 page. Is there a way we can split the pages and display?
    Br,
    Praveen.

    Hi,
    Good question.
    That is not related to WRITE_LIST, it works like that for all ABAP lists: blank lines are not displayed. I don't know any option to view only one page at a time, but you can use PP+ OK code to display the following page.
    Sandra

  • Save report painter output into internal table

    Hi,
      i have created a report painter for vendor aging report. got output in drill down format.
    i need to show the data in smartform as well. so need to save the report painter output into an internal table. can anyone please help me resolving this.
    regards,
    sudha.m

    Hi Sudha
    You can use sample below:
    DATA: list_tab TYPE TABLE OF ABAPLIST.
    SUBMIT NROWS EXPORTING LIST TO MEMORY
                  AND RETURN VIA SELECTION-SCREEN.
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        listobject = list_tab
      EXCEPTIONS
        not_found  = 1
        OTHERS     = 2.
    IF sy-subrc = 0.
      CALL FUNCTION 'WRITE_LIST'
        TABLES
          listobject = list_tab.
    ENDIF.
    Best regards

  • PRoblem regarding Submit - Open/Transfer/Close Dataset

    Hello again, I know I keep asking the same topic (regarding datasets) for the past week. Its been a new topic for me. However, I have a program which I am testing that is shown below.
    <b>REPORT ZPROG_COOL7 NO STANDARD PAGE HEADING.
    DATA: ITAB_LIST TYPE STANDARD TABLE OF ABAPLIST WITH HEADER LINE.
    PARAMETERS: PNAME TYPE SYCPROG. (this does nothing yet ...)
    SUBMIT ZPROGRAM EXPORTING LIST TO MEMORY AND RETURN
                        USING SELECTION-SET 'CEDEX'.
    CALL FUNCTION 'LIST_FROM_MEMORY'
         TABLES
              LISTOBJECT = ITAB_LIST
       EXCEPTIONS
            NOT_FOUND  = 1
            OTHERS     = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    IF SY-SUBRC = 0.
      CALL FUNCTION 'WRITE_LIST'
           TABLES
                LISTOBJECT = ITAB_LIST.
    ENDIF.
    DATA: LD_FILENAME TYPE LOCALFILE.
    DATA: I_MONTH TYPE TABLE OF T247 WITH HEADER LINE.
    DATA: IHTML   TYPE TABLE OF W3HTML  WITH HEADER LINE.
    CALL FUNCTION 'WWW_LIST_TO_HTML'
       EXPORTING
           list_index = sy-lsind
         TABLES
              HTML       = IHTML.
    CLEAR IHTML.
    LD_FILENAME = '
    H******\SAPReport\death.html'.
    OPEN DATASET LD_FILENAME FOR OUTPUT  IN BINARY MODE.
    LOOP AT IHTML.
      TRANSFER IHTML TO LD_FILENAME.
    ENDLOOP.
    CLOSE DATASET LD_FILENAME.
    CLEAR: LD_FILENAME.</b>
    As you can see it is suposed to get a list from a diffrent program, write the list, and then transfer the list into a directory in the SAP application server. This all works fine on foreground but in Background Proccessing the story is diffrent.
    Here is the problem:
    If Iam to send a job in background, the report will generate fine if you view the spool list <b>but there HTML file that is supposed to be saved becomes blank.</b> Is there a way to solve this issue? Thank you all take care, and good day.

    I am concerned that his part does not work in background.
    CALL FUNCTION 'LIST_FROM_MEMORY'
    TABLES
    LISTOBJECT = ITAB_LIST
    * EXCEPTIONS
    * NOT_FOUND = 1
    * OTHERS = 2
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    * WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    IF SY-SUBRC = 0.
    CALL FUNCTION 'WRITE_LIST'
    TABLES
    LISTOBJECT = ITAB_LIST.
    ENDIF.
    DATA: LD_FILENAME TYPE LOCALFILE.
    DATA: I_MONTH TYPE TABLE OF T247 WITH HEADER LINE.
    DATA: IHTML TYPE TABLE OF W3HTML WITH HEADER LINE.
    <b>CALL FUNCTION 'WWW_LIST_TO_HTML'
    * EXPORTING
    * list_index = sy-lsind
    TABLES
    HTML = IHTML.
    CLEAR IHTML.</b>
    LD_FILENAME = '\H******SAPReportdeath.html'.
    OPEN DATASET LD_FILENAME FOR OUTPUT IN BINARY MODE.
    LOOP AT IHTML.
    TRANSFER IHTML TO LD_FILENAME.
    ENDLOOP.
    CLOSE DATASET LD_FILENAME.
    CLEAR: LD_FILENAME.
    I ran across this before and I did find a solution, I'll get back.
    Regards,
    Rich Heilman

  • Regarding fetching the data from Tcode FBL3N output list.

    Hi experts,
    I want to get the data from the FBL3N Transaction output to into my program by giving Company code G/L account number and Fiscal year as input to FBL3N tcode.
    Please guide me how to approach it its urgent.

    Hi Naveen,
    SUBMIT stdreport  EXPORTING LIST TO MEMORY
                  AND RETURN.
    With the above statement you can export the list out put and
    by using the below function module in the your program,
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        listobject = list_tab
      EXCEPTIONS
        not_found  = 1
        OTHERS     = 2.
    IF sy-subrc = 0.
      CALL FUNCTION 'WRITE_LIST'
        TABLES
          listobject = list_tab.
    ENDIF.
    Regards,
    Madhu.

  • Will SUBMIT report EXPORTING LIST TO MEMORY work, when Run in Background?

    You can use SUBMIT <report> EXPORTING LIST TO MEMORY, and then Call the FM LIST_FROM_MEMORY to get the Data.
    This works fine, when the Program is Run in Foreground. My question is, will it work when I Run the Program in Background? i.e. When I Run the Program in Background, will the SUBMIT Statement, Export the List to Memory? Because only then the FM LIST_FROM_MEMORY will get the Data.
    Any alternate solution to meet the same requirement will be appreciated.

    It works for me... my spool output looked like:
    11.01.2008          JC: Calling program - test list to memory                  1                                                                               
    ZLOCAL_JC_SDN_CALLING_PROGRAM                started at 12:54:29                        
    ZLOCAL_JC_SDN_CALLING_PROGRAM                call complete 12:54:30                     
    ZLOCAL_JC_SDN_CALLING_PROGRAM                started at 12:54:30                                                                               
    11.01.2008           JC: Called program - testing list to memory                                                                               
    ZLOCAL_JC_SDN_CALLED_PROGRAM                 was called at: 12:54:29                    
    for the following code:
    report zlocal_jc_sdn_calling_program.
    parameters:
      p_start(1)            type c.
    start-of-selection.
      perform testcase.
    *&      Form  testcase
    form testcase.
      data:
       lt_list              type table of abaplist.
      write: / sy-repid, 'started at', sy-uzeit.
      submit zlocal_jc_sdn_called_program
        exporting list to memory
        and return.
      write: / sy-repid, 'call complete', sy-uzeit.
      call function 'LIST_FROM_MEMORY'
        tables
          listobject = lt_list.
      write: / sy-repid, 'started at', sy-uzeit.
      call function 'WRITE_LIST'
        tables
          listobject = lt_list.
    endform.                    "testcase
    and
    report zlocal_jc_sdn_called_program.
    start-of-selection.
      write: / sy-repid, 'was called at:', sy-uzeit.

  • How to get the output of a background report to be shown on the screen

    When we run the background process it goes to spool request. my requirement is to show it on the screen may be after some time to the user. how can we do that. Thanks in advance

    Hello Varun,
    You cqan submit the report as a JOB and export the out put to memory, once the job is complete you can read the list to display the output.
    Cheers,
    Mano
    Cut & Paste form SAP help.
    Submit report ....
    EXPORTING LIST TO MEMORY
    Does not display the output list of the called report, but saves it in ABAP memory and leaves the called report immediately. Since the calling program can read the list from memory and process it further, you need to use the addition ... AND RETURN . Also, since the called report cannot be requested for printing, the addition ... TO SAP-SPOOL is not allowed here. In addition, you must not assign a function code to the ENTER key in the current GUI status. The saved list is read from the SAP memory using the function module 'LIST_FROM_MEMORY' and can then be saved to the database using EXPORT, for example. You can process this list further with the function modules 'WRITE_LIST', 'DISPLAY_LIST' ... of the function group "SLST".

  • How to get the alv saved in background mode without modifying the program?

    Hi all,
    I have to run a standard report(IW39) in background and save the result ALV as excel or text file.
    How to get the result saved in excel / text format if I don't want to customize the standard program?
    (In the spool, there is an option to save list in file "Spreadsheet", but the saved format is not what we expected.
    It is expected the data to be put is separated in each column / tab-delimited in the text file....)
    Many Thanks!

    I don't have any ready made coding examples, but using the F1 help on SUBMIT statement will help to get you quite a way:
    DATA list_tab TYPE TABLE OF abaplist.
    SUBMIT 'RIAUFK20'
    USING SELECTION-SCREEN
    EXPORTING LIST TO MEMORY
                  AND RETURN.
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        listobject = list_tab
      EXCEPTIONS
        not_found  = 1
        OTHERS     = 2.
    IF sy-subrc = 0.
      CALL FUNCTION 'WRITE_LIST'
        TABLES
          listobject = list_tab.
    ENDIF.
    Edited by: Micky Oestreich on May 18, 2009 8:18 AM

  • Background job for Standard (T-code F.80) and Background Job via Submit (for same standard program) provides separate spool layout

    Hello Experts,
    I am using SUBMIT Program to execute a standard T-code (F.80).
            SUBMIT sapf080 WITH SELECTION-TABLE rspar
                                         AND RETURN.
    When I execute the program in background and compare it with F.80 and execute it in background too, spool layout for both are different.
    For F.80, It is more detailed with every info like doc number, company code and fiscal year with messages, but for my program only messages are displayed in the spool which is getting unconvinient as I don't know for which document number that message was generated.
    Can you please suggest why am I getting 2 different spool layouts for the same program executed in 2 different ways.
    Thanks,
    Ankit Khanna

    Hello,
    Thanks for your replies.
    I have added a list option along with SUBMIT statement to get similar spool layouts.
    Below piece of code will solve the issue.
              DATA list_tab TYPE TABLE OF abaplist.
            SUBMIT sapf080 WITH SELECTION-TABLE rspar EXPORTING LIST TO MEMORY
                          AND RETURN.
            CALL FUNCTION 'LIST_FROM_MEMORY'
              TABLES
                listobject = list_tab
              EXCEPTIONS
                not_found  = 1
                OTHERS     = 2.
            IF sy-subrc = 0.
              CALL FUNCTION 'WRITE_LIST'
                TABLES
                  listobject = list_tab.
            ENDIF.

  • Report to display billing doc

    TABLES : vbfa, vbrk.
    DATA : BEGIN OF itab OCCURS 0 ,
           posnv LIKE vbfa-posnv,
           vbtyp_n LIKE vbfa-vbtyp_n,
           vbelv LIKE vbfa-vbelv,
           vbeln LIKE vbrk-vbeln,
           END OF itab.
    DATA : BEGIN OF itab1 OCCURS 0,
           vbelv LIKE vbfa-vbelv,
           flag TYPE i,
           END OF itab1.
    DATA lv_tabix LIKE sy-tabix.
    DATA flagw TYPE i.
    SELECT-OPTIONS : p_vbelv FOR vbfa-vbelv.
    SELECT aposnv avbtyp_n avbelv bvbeln INTO
      CORRESPONDING FIELDS OF
      TABLE itab FROM ( vbfa AS a INNER JOIN vbrk AS b ON afktyp = bfktyp
      WHERE vbelv IN p_vbelv.
    IF sy-subrc = 0.
      flagw = 1.
    ENDIF.
    SELECT DISTINCT vbelv FROM vbfa INTO
      CORRESPONDING FIELDS OF
      TABLE itab1
      WHERE vbelv IN p_vbelv.
    LOOP AT itab1.
      lv_tabix = sy-tabix.
      READ TABLE itab WITH KEY vbelv = itab1-vbelv
      vbtyp_n = 'M' .
      IF sy-subrc = 0.
        itab1-flag = 1.
        MODIFY itab1 INDEX lv_tabix.
      ENDIF.
    ENDLOOP.
    START-OF-SELECTION.
      IF flagw = 1.
        LOOP AT itab1.
          IF itab1-flag = 1.
            WRITE:/1 itab1-vbelv ,
               'Invoice'  .
          ELSE.
            WRITE:/1 itab1-vbelv ,
             'No Invoice'  .
          ENDIF.
          WRITE: / 'Preceding Item',
                 25 'Document type',
                 45 'Billing Number'.
          WRITE : / sy-uline.
          LOOP AT itab.
            IF itab-vbelv = itab1-vbelv.
              WRITE : /0 itab-posnv,
              27 itab-vbtyp_n,
                 47 itab-vbeln.
            ENDIF.
          ENDLOOP.
        ENDLOOP.
      ENDIF.
    PERFORM line_sel.
    AT LINE-SELECTION.
          FORM line_sel                                                 *
    *FORM line_sel.
    DATA: lv_field(20),
    lv_value(10).
    GET CURSOR FIELD lv_field.
    IF lv_field = itab-vbeln.
       IF NOT lv_value IS INITIAL.
         SET PARAMETER ID 'VF' FIELD 'itab-vbeln'.
         CALL TRANSACTION 'VF03' AND SKIP FIRST SCREEN.
       ENDIF.
    ENDIF.
    *ENDFORM.
      DATA: g(30),
            ref_parameter(30) VALUE 'parameter by reference',
            val_parameter(30) VALUE 'parameter by value',
            field_symbol  LIKE itab-vbeln.
      FIELD-SYMBOLS: <f> TYPE ANY.
    *PERFORM WRITE_LIST USING REF_PARAMETER VAL_PARAMETER.
      ASSIGN itab-vbeln TO <f>.
      GET CURSOR VALUE g.
      WRITE: /   g, sy-subrc.
    *FORM WRITE_LIST USING RP VALUE(VP).
    ASSIGN itab-vbeln TO <F>.
      SET PARAMETER ID 'VF' FIELD g.
      CALL TRANSACTION 'VF03' AND SKIP FIRST SCREEN.
    ENDFORM.
    this is my code if i click each billing document number i should get tht billing document
    its not working can anyone tell me wats the error

    Hi Javed,
    Use this code:
    LOOP AT itab.
    IF itab-vbelv = itab1-vbelv.
    WRITE : /0 itab-posnv,
    27 itab-vbtyp_n,
    47 LOOP AT itab.
    IF itab-vbelv = itab1-vbelv.
    WRITE : /0 itab-posnv,
    27 itab-vbtyp_n,
    47 itab-vbeln.
    HIDE itab-vbeln.
    ENDIF.
    ENDLOOP.
    Reward is helpful,
    Regards,
    Tanmay

  • Calling a report from a remote system

    Hello All,
    Any idea on this issue will be of great help.
    The scenario is like this.
    a. There are two SAP systems. SYS1 and SYS2.
    b. SYS2 has ALV reports which need to be executed from SYS1.
    c. I applied the following logic which successfully calls the report in SYS1 but does not show up in the ALV format.
    d. The following is the logic used.
    There is an RFC enabled function module in SYS2 that has the statement SUBMIT EXPORTING.... Within the same FM, the LIST_MEMORY imports the report contents. This FM since it is being called from SYS1, sends back the imported contents from SYS2 to SYS1.
    e. In SYS1, the WRITE_LIST is being used that prints the report.  BUT THIS SHOWS THE OUTPUT in the form of a normal report.
    My question is, how do I show the contents in the ALV format.
    Please note,, the reuse_alv..list..display FM cannot be used as the internal table that is imported in SYS1 has the data in the RAW format.
    Any help??/
    Thanks for your time

    Yes, you can do that using the RFC, but you won't be able to send any parameters thru the selection screen.
    report zrich_0003 no standard page heading.
    data: source type table of  PROGTAB with header line,
          output like listzeile occurs 10 with header line.
    call function 'RFC_ABAP_INSTALL_AND_RUN'
               destination <system_name>
             exporting
               mode                = space
               programname         = <the_program_name>
             tables
                program            = source
                writes             = output.
    loop at output.
      write:/ output.
    endloop.
    Regards,
    Rich Heilman
    Message was edited by: Rich Heilman

  • Converting ASCI to HTML format

    hello all,
             i have a requirment where i need submit a report output to memory than convert the memory data to asci. till where i was succusfull but i need to display this table data into html layout in bsp application where i am getting junk characters.
              is there any function module where i could convert my asci data into html and display on my layout of bsp application or is there any other way to get out of this problem.
    thanks in advance,
    raju

    Hai N
    SUBMIT rep.
    Additions
    1. ... LINE-SIZE col
    2. ... LINE-COUNT lin
    3. ... TO SAP-SPOOL
    4. ... VIA SELECTION-SCREEN
    5. ... AND RETURN
    6. ... EXPORTING LIST TO MEMORY
    7. ... USER user VIA JOB job NUMBER n
    8. ... Various additions for parameter transfer to rep
    9. ... USING SELECTION-SETS OF PROGRAM prog
    Effect
    Calls the report rep . Leaves the active program and starts the new report rep .
    Addition 1
    ... LINE-SIZE col
    Effect
    Prints the report with the line width col .
    Addition 2
    ... LINE-COUNT lin
    Effect
    Prints the report with lin lines (per page).
    Addition 4
    ... VIA SELECTION-SCREEN
    Effect
    Displays the selection screen for the user. In this case, the selection screen is redisplayed after return from the report list display - the user's entries are retained.
    Addition 5
    ... AND RETURN
    Effect
    Returns to the calling transaction or program after the called program has been executed. SUBMIT ... AND RETURN creates a new internal mode .
    Addition 6
    ... EXPORTING LIST TO MEMORY
    Effect
    Does not display the output list of the called report, but saves it in SAP memory and leaves the called report immediately. Since the calling program can read the list from memory and process it further, you need to use the addition ... AND RETURN . Also, since the called report cannot be requested for printing, the addition ... TO SAP-SPOOL is not allowed here. You can read the saved list from SAP memory with the function module 'LIST_FROM_MEMORY' and then (for example) store it in the database with EXPORT . You can process this list further with the function modules 'WRITE_LIST' , 'DISPLAY_LIST' ... of the function group "SLST" .
    Addition 7
    ... USER user VIA JOB job NUMBER n
    Effect
    Schedules the specified report in the job specified by the job name job and the job number n . The job runs under the user name user and you can omit the addition USER user . The assignment of the job number occurs via the function module JOB_OPEN (see also the documentation for the function modules JOB_CLOSE and JOB_SUBMIT . This addition can only be used with the addition ...AND RETURN .
    Note
    When scheduling a report with the SUBMIT ... VIA JOB job NUMBER n statement, you should always use the addition ...TO SAP-SPOOL to pass print and/or archive parameters. Otherwise, default values are used to generate the list and this disturbs operations in a production environment.
    Addition 9
    ... USING SELECTION-SETS OF PROGRAM prog
    Effect
    Uses variants of the program prog when executing the program rep .
    Note
    Important
    The programs prog and rep must have the same SELECT-OPTIONS and PARAMETER s. Otherwise, variants of the program prog may be destroyed.
    Note
    When using this addition, the specified variant vari of the program prog is taken in USING SELECTION-SET vari . On the other hand, all variant-related actions on the selection screen of rep (Get , Save as variant , Display , Delete ) refer to the variants of prog .
    Example
    SUBMIT REPORT01
    VIA SELECTION-SCREEN
    USING SELECTION-SET 'VARIANT1'
    USING SELECTION-SETS OF PROGRAM 'REPORT00'
    AND RETURN.
    Effect
    Executes the program REPORT01 with the variant VARIANT1 of the program REPORT00 .
    Note
    Runtime errors
    LOAD_PROGRAM_NOT_FOUND : The specified program was not found.
    SUBMIT_WRONG_TYPE : The specified program is not a report.
    SUBMIT_IMPORT_ONLY_PARAMETER : Only one value passed to a report parameter.
    SUBMIT_WRONG_SIGN : Invalid value passed to a selection with the addition SIGN .
    SUBMIT_IN_ITAB_ILL_STRUCTURE : Table passed to a selection with WITH sel IN itab had an unexpected structure.
    Try with this Example
    Data: listobject like abaplist occurs 1 with header line.
    CALL FUNCTION 'LIST_FROM_MEMORY'
    TABLES
    listobject = listobject
    EXCEPTIONS
    OTHERS = 1 .
    IF sy-subrc <> 0.
    message ID '61' TYPE 'E' NUMBER '731'
    with 'LIST_FROM_MEMORY'.
    ENDIF.
    Thanks & regards
    Sreenivasulu P

  • How to find multiple transport requests for one object

    Hi all,
    Is there any function module which will fetches multiple transport requests ( if created ) for one object.I tried almost all the function modules , but i didn't got the solution.
    I need to develop a report ,   which will takes a single Task number as input and gets the Request number from table E070.
    Based on that Request Number i will fetch remaining Task numbers under it.
    Then for all the Tasks Numbers, i am fetching their  objects by using table E071.
    I need to list out  whether any of these objects are in multiple Transport Requests. Once i got all the Transport Request numbers i need to release the Request based on their Transport Request sequence.
    I tried the following FM's , but not able to get the solution.
    SVRS_DISPLAY_VERSION_LIST
    SVRS_GET_VERSION_DIRECTORY_46
    SVRS_GATHER_REQUEST_FRAGS
    Thanks..

    Hello
    I have tried with below code
    DATA list_tab TYPE TABLE OF abaplist.
    SUBMIT RSWBO040 USING SELECTION-SET 'TEST'
                    EXPORTING LIST TO MEMORY
                   AND RETURN.
    CALL FUNCTION 'LIST_FROM_MEMORY'
       TABLES
         listobject = list_tab
       EXCEPTIONS
         not_found  = 1
         OTHERS           = 2.
    IF sy-subrc = 0.
       CALL FUNCTION 'WRITE_LIST'
         TABLES
           listobject = list_tab.
    ENDIF.
    break-point.
    Submitting the program(RSWBO040) of SE03 transaction a will result in 'CNTL_ERROR' dump.
    Please try some other options
    Thanks

  • PASSING A TABLE TO ANOTHER PROGRAM

    HII FRNDS
    CAN WE PASS A TABLE TO ANOTHER PROGRAM . I AM CALING THAT PROGRAM USING SUBMIT COMMAND.
    tHANKX
    ROHIT

    check this sample code..
    DATA list_tab TYPE TABLE OF abaplist.
    SUBMIT report EXPORTING LIST TO MEMORY
                  AND RETURN.
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        listobject = list_tab
      EXCEPTIONS
        not_found  = 1
        OTHERS     = 2.
    IF sy-subrc = 0.
      CALL FUNCTION 'WRITE_LIST'
        TABLES
          listobject = list_tab.
    ENDIF.
    hope this helps...

  • SUBMIT statement

    Hello All,
    I am using SUBMIT to call a program from within another program.
    My requirement is to capture the MESSAGES thrown by the called program in the calling program.
    Here is the code snippet:
    DATA: list_tab TYPE TABLE OF abaplist.
    Data: begin of wa_text,
          c type c,
          end of wa_text,
          t_text like standard TABLE OF wa_text.
    Submit zkh_called_prog EXPORTING LIST TO MEMORY and return.
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        LISTOBJECT       = list_tab
    EXCEPTIONS
       NOT_FOUND        = 1
       OTHERS           = 2
    CALL FUNCTION 'LIST_TO_TXT'
    EXPORTING
       LIST_INDEX               = -1
      TABLES
        LISTTXT                  = t_text
       LISTOBJECT               = list_tab
    * EXCEPTIONS
    *   EMPTY_LIST               = 1
    *   LIST_INDEX_INVALID       = 2
    *   OTHERS                   = 3
    IF sy-subrc = 0.
      CALL FUNCTION 'WRITE_LIST'
        TABLES
          listobject = list_tab.
    ENDIF.
    By this I am able to get the output of WRITE statements in the t_text internal table. But I am not able to get the Error/ Status Messages in this table.
    Can anyone suggest a way of capturing the messages in the calling program
    Regards,
    Khushboo

    Hi khushbu.
    better u try like this.
    submit callingprogram
                with s_spart in s_spart
                with p_spmon eq p_spmon
                and return.
    u have to take care taht the parameters must be same....in the calling and called program.
    then capture msg.
    reward points if found helpful
    thnx
    prashant

Maybe you are looking for

  • Help with windowListener please

    Can someone please tell me what i'm doing wrong here? The program is pretty simple. It only writes input to a file. The problem is that the WindowListener is not working like I expected. Thanks for any help. I expected the windowListener part of the

  • Automatic adjusting of the volum level

    Does anybody know in witch way/how the player does the automatic adjusting of the volum level? How does the automatic adjusting of the volum level work? Is it just the decibel that is "normalising"? How does the player measure it? Are the frequenses

  • Error .dmp

    i am developing a new page, The page consists of link buttons and click of these link buttons it’s taking us to new form, on double click of the values in matrix in new form it’s giving the error .dmp file is created and please contact support for fu

  • Forgot my Time Capsule password.

    I forgot my Time Capsule password--or rather, I am trying to enter the password that aI estblished (which I wrote down!!!) but it seems not to be working. I have tried to follow the instructions for a soft reset (i.e., hold in the reset button for on

  • Wls accepts no localhost connections in strange way

    hi *, i have a strange behaviour with one of my wls servers: its a cluster of 6 machines 1 machine admin + worker 5 worker the strange behaviour is that i cannot access the application via localhost on the server where the admin is located. on the ot