Friday, October 26, 2012

Change Selection Text in Standard Program

       



        DATA: it_tab TYPE TABLE OF rsseltexts.
        DATA: is_tab TYPE rsseltexts.
        is_tab-name = 'ZPARAMETER'. " parameter name
        is_tab-kind = 'P'.  " P/S type
        is_tab-text = 'Manager'. " Description
        APPEND is_tab TO it_tab.    

        CALL FUNCTION 'SELECTION_TEXTS_MODIFY'
          EXPORTING
            program                     'RCATS_DISPLAY_ACTIVITIES' " Report Name
          TABLES
            seltexts                    = it_tab
          EXCEPTIONS
            program_not_found           = 1
            program_cannot_be_generated = 2
            OTHERS                      3.
        IF sy-subrc <> 0.
          MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                  WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        ENDIF.