Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Need help on Submit and Return for rm07mlbd (MB5B)

Former Member
0 Likes
3,432

Hi people, I need a little help on Submit and return with program  rm07mlbd (MB5B), following is the block of code I have written, but i not getting a way to catch the data from that program:

SUBMIT rm07mlbd WITH matnr    IN it_mvke

                   WITH bukrs    eq s_bukrs-low

                   WITH datum    IN s_date

                   WITH lgbst    EQ 'X'

                   WITH bwbst    EQ ''

                   WITH sbbst    EQ ''

                   WITH pa_sumfl EQ 'X'

                   EXPORTING LIST TO MEMORY AND RETURN.

IMPORT bestand TO gt_bestand FROM MEMORY ID 'MB5B_RESULT'.

Hi people, I need a little help on Submit and return with program  rm07mlbd (MB5B), following is the block of code I have written, but i not getting a way to catch the data from that program:

SUBMIT rm07mlbd WITH matnr    IN it_mvke

                   WITH bukrs    eq s_bukrs-low

                   WITH datum    IN s_date

                   WITH lgbst    EQ 'X'

                   WITH bwbst    EQ ''

                   WITH sbbst    EQ ''

                   WITH pa_sumfl EQ 'X'

                   EXPORTING LIST TO MEMORY AND RETURN.

IMPORT bestand TO gt_bestand FROM MEMORY ID 'MB5B_RESULT'.

2 REPLIES 2
Read only

paul_bakker2
Active Contributor
0 Likes
1,959

I'm pretty sure you could have found the solution by searching SCN, but anyway:

       CALL FUNCTION 'LIST_FROM_MEMORY'

            TABLES

                 LISTOBJECT = LT_ABAPLIST

            EXCEPTIONS

                 NOT_FOUND  = 01.

       CALL FUNCTION 'LIST_TO_ASCI'

            TABLES

                 LISTASCI   = lt_output

                 LISTOBJECT = LT_ABAPLIST

            EXCEPTIONS

                 EMPTY_LIST = 01.

LT_OUTPUT is now filled with a number of (256-char) lines, showing

what would have otherwise appeared on the report (lines and all).

Read only

Sandra_Rossi
Active Contributor
0 Likes
1,959

If you read entirely the relevant part of the ABAP documentation for SUBMIT EXPORTING LIST TO MEMORY, then you'll see that your excerpt misses the call to the function module LIST_FROM_MEMORY !