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

What function module to use /

Former Member
0 Likes
539

HI,

I AM LOOKING FOR A FUNCTION MODULE WHICH WILL GIVE ALL THE F4 CHECK VALUES OF A PARTICULAR FIELD WHEN THE TABLE NAME AND THE FIELD NAME PASSED TO IT.

Thanks.

Tushar.

2 REPLIES 2
Read only

thomas_jung
Developer Advocate
Developer Advocate
0 Likes
382

What release are you on?

In 620 and higher there is a class that will do that with a data object reference:

call method cl_bsp_services=>if_bsp_services~get_simple_helpvalues2
        exporting
          data_object_ref = field
        changing
          helpvalue_tab2  = help1.

Perhaps the code in there will help as well:

You can use the RTTI to get fixed values:

data: rtti type ref to cl_abap_elemdescr.
call method rtti->get_ddic_fixed_values
    receiving
      p_fixed_values = fixvalues.

If the Data Dictionary shows an attached search help, you can call the following to get those values:

" Select the value help description in the local system:
  call function 'F4UT_VISUALIZATION_GET'
    exporting
      tabname           = l_typename
      fieldname         = l_compname
    importing
      keyfield          = l_keyfield
      valuefield        = l_valuefield
    tables
      value_tab         = f4_visual_tab
    changing
      shlp              = l_shlp
    exceptions
      field_not_found   = 1
      no_help_for_field = 2
      inconsistent_help = 3
      others            = 4.

Read only

Former Member
0 Likes
382

Check this FM

FUNCTION STF4_CHECK_DOMAIN_VALUE_TEXT.

*"----


""Lokale Schnittstelle:

*" IMPORTING

*" VALUE(IV_DOMNAME) LIKE DD01L-DOMNAME

*" VALUE(IV_VALUE_TEXT) LIKE DD07T-DDTEXT

*" EXPORTING

*" VALUE(EV_VALUE)

*" EXCEPTIONS

*" VALUE_NOT_FOUND

*" NO_VALUES

*"----