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

search help

Former Member
0 Likes
587

hi experts,

can anyone please help me to fill the values in the search help through any FM.

thanks in advance.

1 ACCEPTED SOLUTION
Read only

Former Member

hi experts,

can anyone please help me to fill the values in the search help through any FM.

thanks in advance.

5 REPLIES 5
Read only

Former Member
Read only

Former Member
0 Likes
553

Hi,

Try using the function module 'F4_INT_TABLE_VALUE_REQUEST'

CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'

EXPORTING

retfield = <table field name>

dynpprog = sy-repid

dynpnr = sy-dynnr

dynprofield = <select option name>

value_org = 'S'

TABLES

value_tab = <internal table>

EXCEPTIONS

parameter_error = 1

no_values_found = 2

OTHERS = 3.

Internal table - which contains the values to be displayed in the search help.

Sharin.

Read only

Former Member
0 Likes
553

hi,

check this FM

help_values_get_with_table

IMPORTING

VALUE(CUCOL) LIKE SY-CUCOL DEFAULT 0

VALUE(CUROW) LIKE SY-CUROW DEFAULT 0

VALUE(DISPLAY) DEFAULT SPACE

VALUE(FIELDNAME) LIKE HELP_INFO-FIELDNAME DEFAULT SPACE

VALUE(TABNAME) LIKE HELP_INFO-TABNAME DEFAULT SPACE

VALUE(NO_MARKING_OF_CHECKVALUE) DEFAULT SPACE

VALUE(TITLE_IN_VALUES_LIST) DEFAULT SPACE

VALUE(TITEL) DEFAULT SPACE

VALUE(SHOW_ALL_VALUES_AT_FIRST_TIME) DEFAULT SPACE

VALUE(NO_CONVERSION) DEFAULT SPACE

EXPORTING

VALUE(SELECT_VALUE)

TABLES

FIELDS STRUCTURE HELP_VALUE

VALUETAB

EXCEPTIONS

FIELD_NOT_IN_DDIC

MORE_THEN_ONE_SELECTFIELD

NO_SELECTFIELD

Regards,

Anirban

Read only

Former Member
0 Likes
553

Hi Manish.

I would like to suggest my opinion,

[SDN - Reference - Adding F4 help for the custom field of a custom table using Function Module|;

[SDN - Reference - Search help added in se11 in standard table|;

Hope this works out well.

Good Luck & Regards.

Harsh Dave

Read only

Former Member
0 Likes
553

Hi Manish,

Check out these function modules:

HELP_VALUES_GET_WITH_TABLE - Show a list of possible values for F4 popup help on selection screens. This function module pops up a screen that is just like all the other F4 helps, so it looks like the rest of the SAP system. Very useful for providing dropdowns on fields that do not have them predefined.

F4_IF_FIELD_VALUE_REQUEST - Use values from a DDIC table to provide a list of possible values. TABNAME and FIELDNAME are required fields, and when MULTIPLE_CHOICE is selected, more than one value can be returned.

F4IF_INT_TABLE_VALUE_REQUEST - F4 help that returns the values selected in an internal table. Very handy when programming your very own F4 help for a field.

check this example:

data:
    begin of t_values occurs 2,
      value like kna1-begru,
    end of t_values,

    t_return like ddshretval occurs 0 with header line.

  t_values = 'PAR*'.
  append t_values.

  t_values = 'UGG'.
  append t_values.

  call function 'F4IF_INT_TABLE_VALUE_REQUEST'
       exporting
            retfield        = 'BEGRU'
            value_org       = 'S'
       tables
            value_tab       = t_values
            return_tab      = t_return
       exceptions
            parameter_error = 1
            no_values_found = 2
            others          = 3.

  if sy-subrc = 0.
    read table t_return index 1.

    o_begru-low = t_return-fieldval.

    if o_begru-low = 'PAR*'.
      o_begru-option = 'CP'.
    else.
      o_begru-option = 'EQ'.
    endif.

    o_begru-sign = 'I'.

    append o_begru to s_begru.
  else.
    o_begru = i_begru.
  endif.

Regards,

Chandra Sekhar