SAP Reports / Programs

RM07MSTO SAP ABAP Report - Cancelled Material Documents







RM07MSTO is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for The report Cancelled material documents issues a list with the following data: see full standard documentation available for this report. Also check out the submitted Comments related to this SAP report and the details below to see which OBJECTS it interacts with such as TABLES, FUNCTION MODULES, INCLUDES ETC.

If you would like to execute this report or see the full code listing simply enter RM07MSTO into the relevant SAP transactions such as SE38 or SE80


Transaction Code(s):

Below is a list of transaction codes which are relevant to this SAP report

MBSM - Display Cancelled Material Docs.


ABAP code to call this SAP report using the submit statement

This report can be called from another progam/report simply by using the ABAP SUBMIT statement, see below for example ABAP code snipts of how to do this.






SUBMIT RM07MSTO. "Basic submit
SUBMIT RM07MSTO AND RETURN. "Return to original report after report execution complete
SUBMIT RM07MSTO VIA SELECTION-SCREEN. "Display selection screen of submitted report to user
    See more syntax options for the ABAP SUBMIT statement


Text pool values


Selection Text: WERKS = D Plant
Selection Text: USNAM = D User Name
Selection Text: SMBLN = Reversal Document
Selection Text: SJAHR = Year of Reversal Document
Selection Text: P_VARI = Layout
Selection Text: MJAHR = Year of Original Document
Selection Text: MBLNR = Original Document
Selection Text: MATNR = D Material
Selection Text: BUDAT = D Posting Date
Title: Cancelled Material Documents
Text Symbol: 051 = Original Document
Text Symbol: 050 = Reversal Document
Text Symbol: 043 = Original Mat. Document Year
Text Symbol: 042 = Orig. Mat. Year
Text Symbol: 041 = OrigMYr
Text Symbol: 039 = Original Material Document
Text Symbol: 038 = Original Mat. Doc.
Text Symbol: 037 = OrigMDoc
Text Symbol: 036 = Reversal Mat. Doc. Year
Text Symbol: 035 = ReversMatYr
Text Symbol: 034 = RevMYr
Text Symbol: 033 = Reversal Material Doc.
Text Symbol: 032 = ReversMatDoc
Text Symbol: 031 = RevMDoc
Text Symbol: 020 = Display Options
Text Symbol: 018 = A document no.
Text Symbol: 005 = Database Selections


INCLUDES used within this REPORT RM07MSTO

INCLUDE RM07ALVI. "N1527378


TABLES used within REPORT and the associated SELECT statement:





No SAP DATABASE tables are accessed within this REPORT code!


Function Modules used within report and the associated call statement:

REUSE_ALV_LIST_DISPLAY * CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' "n1527378 CALL FUNCTION alv_detail_func "n1527378 EXPORTING i_interface_check = l_flag_interface_check "n1527378 i_callback_program = l_repid i_callback_pf_status_set = 'STATUS_SET' i_callback_user_command = 'USER_COMMAND_MAIN' is_layout = ls_layout it_fieldcat = lt_fc it_sort = lt_sort i_default = 'X' i_save = 'A' is_variant = gs_variant is_print = ls_print TABLES t_outtab = belege.

REUSE_ALV_HIERSEQ_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_HIERSEQ_LIST_DISPLAY' EXPORTING i_callback_program = l_repid i_callback_pf_status_set = 'STATUS_SET_DETAIL' i_callback_user_command = 'USER_COMMAND_DETAIL' is_layout = ls_layout it_fieldcat = lt_fc i_default = 'X' i_save = 'A' is_variant = ls_variant i_tabname_header = 'HEADER' i_tabname_item = 'DETAIL' is_keyinfo = ls_keyinfo is_print = ls_print TABLES t_outtab_header = header t_outtab_item = detail.

MIGO_DIALOG CALL FUNCTION 'MIGO_DIALOG' "1810419 EXPORTING i_action = 'A04' i_refdoc = 'R02' i_notree = 'X' i_no_auth_check = ' ' i_deadend = 'X' i_skip_first_screen = 'X' i_okcode = 'OK_GO' i_mblnr = i_mblnr i_mjahr = i_mjahr.

AC_DOCUMENT_RECORD CALL FUNCTION 'AC_DOCUMENT_RECORD' EXPORTING i_awtyp = 'MKPF' i_awref = l_awref i_aworg = l_aworg EXCEPTIONS error_message = 4.

REUSE_ALV_VARIANT_DEFAULT_GET * CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET' * EXPORTING * i_save = 'A' * CHANGING * cs_variant = ls_variant * EXCEPTIONS * not_found = 2.

REUSE_ALV_VARIANT_F4 CALL FUNCTION 'REUSE_ALV_VARIANT_F4' EXPORTING is_variant = ls_variant_imp i_save = 'A' IMPORTING e_exit = l_exit es_variant = ls_variant_exp EXCEPTIONS not_found = 2.

REUSE_ALV_VARIANT_EXISTENCE CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE' EXPORTING i_save = 'A' CHANGING cs_variant = gs_variant.



Contribute (Add Comments)

Although this basic information may have limited use it does provide an easy to find location to store any knowledge about this program/report.







The contribute/comments section below therefore offer's an opportunity for anyone to add additional information. This can be anything from useful hints, tips and screen shots to relevant SAP notes or anything else you feel is relevant to this report.

This will then be available for everyone to easily find by simply searching on the report name RM07MSTO or its description.