SAP Function Modules

BTFR_BROWSER SAP Function module







BTFR_BROWSER is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name BTFR_BROWSER into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: BTFR_API_MAINTENANCE
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM BTFR_BROWSER - BTFR BROWSER





CALL FUNCTION 'BTFR_BROWSER' "
* EXPORTING
*   package_tab =               " btfr_package_tt  Packages
*   object_type =               " trobjtype     Object Type
*   object_name =               " trobj_name    Object Name in Object List
*   search_alias =              " sotr_alias
*   search_text =               " sotr_txt
*   langu = SY-LANGU            " spras         Language Key
*   flag_string =               " btfr_f_string  Indicator: 'X': Long Text (String), ' ': Short Text
*   flag_get_all_contexts =     " btfr_flag
*   flag_only_with_alias =      " btfr_flag
*   flag_with_sel_screen =      " btfr_flag
*   flag_display =              " btfr_flag
*   browser_mode = 'MODAL'      " c
*   start_row = 5               " sycurow
*   start_col = 5               " sycucol
*   flag_get_data_from_memory =   " btfr_flag   (internal usage)
*   progname =                  " syrepid       (internal usage)
*   dynnr =                     " sydynnr       (internal usage)
  IMPORTING
    flag_cancelled =            " btfr_flag
    header =                    " btfr_head     Structure for Header Fields
    text =                      " btfr_text     Short Texts (fields from SOTR_TEXT that are used)
    string =                    " btfr_string   Long Texts (fields from SOTR_TEXTU that are used)
    text_tab =                  " btfr_text_tt  (internal usage)
    string_tab =                " btfr_string_tt  (internal usage)
  EXCEPTIONS
    INVALID_OBJECT_TYPE = 1     "
    NO_ENTRY_FOUND = 2          "
    .  "  BTFR_BROWSER

ABAP code example for Function Module BTFR_BROWSER





The ABAP code below is a full code listing to execute function module BTFR_BROWSER including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
ld_flag_cancelled  TYPE BTFR_FLAG ,
ld_header  TYPE BTFR_HEAD ,
ld_text  TYPE BTFR_TEXT ,
ld_string  TYPE BTFR_STRING ,
ld_text_tab  TYPE BTFR_TEXT_TT ,
ld_string_tab  TYPE BTFR_STRING_TT .

DATA(ld_package_tab) = 'Check type of data required'.
DATA(ld_object_type) = 'Check type of data required'.
DATA(ld_object_name) = 'Check type of data required'.
DATA(ld_search_alias) = 'Check type of data required'.
DATA(ld_search_text) = 'Check type of data required'.
DATA(ld_langu) = 'Check type of data required'.
DATA(ld_flag_string) = 'Check type of data required'.
DATA(ld_flag_get_all_contexts) = 'Check type of data required'.
DATA(ld_flag_only_with_alias) = 'Check type of data required'.
DATA(ld_flag_with_sel_screen) = 'Check type of data required'.
DATA(ld_flag_display) = 'Check type of data required'.
DATA(ld_browser_mode) = 'Check type of data required'.
DATA(ld_start_row) = '123 '.
DATA(ld_start_col) = '123 '.
DATA(ld_flag_get_data_from_memory) = 'Check type of data required'.
DATA(ld_progname) = '123 '.
DATA(ld_dynnr) = 'some text here'. . CALL FUNCTION 'BTFR_BROWSER' * EXPORTING * package_tab = ld_package_tab * object_type = ld_object_type * object_name = ld_object_name * search_alias = ld_search_alias * search_text = ld_search_text * langu = ld_langu * flag_string = ld_flag_string * flag_get_all_contexts = ld_flag_get_all_contexts * flag_only_with_alias = ld_flag_only_with_alias * flag_with_sel_screen = ld_flag_with_sel_screen * flag_display = ld_flag_display * browser_mode = ld_browser_mode * start_row = ld_start_row * start_col = ld_start_col * flag_get_data_from_memory = ld_flag_get_data_from_memory * progname = ld_progname * dynnr = ld_dynnr IMPORTING flag_cancelled = ld_flag_cancelled header = ld_header text = ld_text string = ld_string text_tab = ld_text_tab string_tab = ld_string_tab EXCEPTIONS INVALID_OBJECT_TYPE = 1 NO_ENTRY_FOUND = 2 . " BTFR_BROWSER
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_flag_cancelled  TYPE BTFR_FLAG ,
ld_package_tab  TYPE BTFR_PACKAGE_TT ,
ld_header  TYPE BTFR_HEAD ,
ld_object_type  TYPE TROBJTYPE ,
ld_text  TYPE BTFR_TEXT ,
ld_object_name  TYPE TROBJ_NAME ,
ld_string  TYPE BTFR_STRING ,
ld_search_alias  TYPE SOTR_ALIAS ,
ld_text_tab  TYPE BTFR_TEXT_TT ,
ld_search_text  TYPE SOTR_TXT ,
ld_string_tab  TYPE BTFR_STRING_TT ,
ld_langu  TYPE SPRAS ,
ld_flag_string  TYPE BTFR_F_STRING ,
ld_flag_get_all_contexts  TYPE BTFR_FLAG ,
ld_flag_only_with_alias  TYPE BTFR_FLAG ,
ld_flag_with_sel_screen  TYPE BTFR_FLAG ,
ld_flag_display  TYPE BTFR_FLAG ,
ld_browser_mode  TYPE C ,
ld_start_row  TYPE SYCUROW ,
ld_start_col  TYPE SYCUCOL ,
ld_flag_get_data_from_memory  TYPE BTFR_FLAG ,
ld_progname  TYPE SYREPID ,
ld_dynnr  TYPE SYDYNNR .

ld_package_tab = 'some text here'.
ld_object_type = 'some text here'.
ld_object_name = 'some text here'.
ld_search_alias = 'some text here'.
ld_search_text = 'some text here'.
ld_langu = 'some text here'.
ld_flag_string = 'some text here'.
ld_flag_get_all_contexts = 'some text here'.
ld_flag_only_with_alias = 'some text here'.
ld_flag_with_sel_screen = 'some text here'.
ld_flag_display = 'some text here'.
ld_browser_mode = 'some text here'.
ld_start_row = '123 '.
ld_start_col = '123 '.
ld_flag_get_data_from_memory = 'Check type of data required'.
ld_progname = '123 '.
ld_dynnr = 'some text here'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name BTFR_BROWSER or its description.