Application Development 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: 

Search Help via function module

Former Member
0 Kudos

Hi !

I developped a search-help exit like F4IF_SHLP_EXIT_EXAMPLE. And now I want to enable F4 value help for the rectriction parameters. I know this FM to enable required parameters ( F4UT_PARAMETER_REQUIRED) I need some similar to enable F4 help.

Could anyone lead me to some documents or some tips I that could be usefull to me ?

Thanks a lot,

1 ACCEPTED SOLUTION

Former Member
0 Kudos

This might help you...........

function module for search help F4IF_SHLP_EXIT_EXAMPLE

dynamic search help use 'F4IF_INT_TABLE_VALUE_REQUEST'

please check out the link below it will help you

A repository object maintained in the ABAP Dictionary. It supplies input fields on Dynpros with single- or multi-column input helps. Search helps can be linked in the Dictionary with components from structures, data elements, and check tables. A search help enables you to search for entry values with assigned data, without you having to know the exact spelling of the value.

http://help.sap.com/saphelp_46c/helpdata/EN/cf/21ee52446011d189700000e8322d00/content.htm

-


please explain in details with step by step process.

create a search help exit:

1. create an fm with this interface:

*" TABLES

*" SHLP_TAB TYPE SHLP_DESCR_TAB_T

*" RECORD_TAB STRUCTURE SEAHLPRES

*" CHANGING

*" VALUE(SHLP) TYPE SHLP_DESCR_T

*" VALUE(CALLCONTROL) LIKE DDSHF4CTRL STRUCTURE DDSHF4CTRL

put this logic in it:

  • Delete duplicate filter logic.

  • This logic only needs to apply at the 'DISP' event - which is just

  • before the hit list is displayed

if callcontrol-step = 'DISP'.

delete adjacent duplicates from record_tab.

endif.

2. edit your search help in se11 and enter the name of the above search help exit fm

-


check this sample code..for dynamic search help

REPORT ZTEST_F4HELP .

*---Report with selection screen and to display the list of

  • possible entries for field 'B' as per the value in field 'A'.

parameters: p_vbeln type vbak-vbeln,

p_posnr type vbap-posnr.

at selection-screen on value-request for p_posnr.

data: begin of help_item occurs 0,

posnr type vbap-posnr,

matnr type vbap-matnr,

arktx type vbap-arktx,

end of help_item.

data: dynfields type table of dynpread with header line.

dynfields-fieldname = 'P_VBELN'.

append dynfields.

call function 'DYNP_VALUES_READ'

exporting

dyname = sy-cprog

dynumb = sy-dynnr

translate_to_upper = 'X'

tables

dynpfields = dynfields

exceptions

invalid_abapworkarea = 1

invalid_dynprofield = 2

invalid_dynproname = 3

invalid_dynpronummer = 4

invalid_request = 5

no_fielddescription = 6

invalid_parameter = 7

undefind_error = 8

double_conversion = 9

stepl_not_found = 10

others = 11.

read table dynfields with key fieldname = 'P_VBELN'.

p_vbeln = dynfields-fieldvalue.

call function 'CONVERSION_EXIT_ALPHA_INPUT'

exporting

input = p_vbeln

importing

output = p_vbeln.

select posnr matnr arktx into table help_item

from vbap

where vbeln = p_vbeln.

call function 'F4IF_INT_TABLE_VALUE_REQUEST'

exporting

retfield = 'POSNR'

dynprofield = 'P_POSNR'

dynpprog = sy-cprog

dynpnr = sy-dynnr

value_org = 'S'

tables

value_tab = help_item.

-


also check this link it will help you

/message/3854825#3854825 [original link is broken]

Regards,

Pavan

3 REPLIES 3

hymavathi_oruganti
Active Contributor
0 Kudos

f4int_table_value_display

0 Kudos

I cant find this FM.

Former Member
0 Kudos

This might help you...........

function module for search help F4IF_SHLP_EXIT_EXAMPLE

dynamic search help use 'F4IF_INT_TABLE_VALUE_REQUEST'

please check out the link below it will help you

A repository object maintained in the ABAP Dictionary. It supplies input fields on Dynpros with single- or multi-column input helps. Search helps can be linked in the Dictionary with components from structures, data elements, and check tables. A search help enables you to search for entry values with assigned data, without you having to know the exact spelling of the value.

http://help.sap.com/saphelp_46c/helpdata/EN/cf/21ee52446011d189700000e8322d00/content.htm

-


please explain in details with step by step process.

create a search help exit:

1. create an fm with this interface:

*" TABLES

*" SHLP_TAB TYPE SHLP_DESCR_TAB_T

*" RECORD_TAB STRUCTURE SEAHLPRES

*" CHANGING

*" VALUE(SHLP) TYPE SHLP_DESCR_T

*" VALUE(CALLCONTROL) LIKE DDSHF4CTRL STRUCTURE DDSHF4CTRL

put this logic in it:

  • Delete duplicate filter logic.

  • This logic only needs to apply at the 'DISP' event - which is just

  • before the hit list is displayed

if callcontrol-step = 'DISP'.

delete adjacent duplicates from record_tab.

endif.

2. edit your search help in se11 and enter the name of the above search help exit fm

-


check this sample code..for dynamic search help

REPORT ZTEST_F4HELP .

*---Report with selection screen and to display the list of

  • possible entries for field 'B' as per the value in field 'A'.

parameters: p_vbeln type vbak-vbeln,

p_posnr type vbap-posnr.

at selection-screen on value-request for p_posnr.

data: begin of help_item occurs 0,

posnr type vbap-posnr,

matnr type vbap-matnr,

arktx type vbap-arktx,

end of help_item.

data: dynfields type table of dynpread with header line.

dynfields-fieldname = 'P_VBELN'.

append dynfields.

call function 'DYNP_VALUES_READ'

exporting

dyname = sy-cprog

dynumb = sy-dynnr

translate_to_upper = 'X'

tables

dynpfields = dynfields

exceptions

invalid_abapworkarea = 1

invalid_dynprofield = 2

invalid_dynproname = 3

invalid_dynpronummer = 4

invalid_request = 5

no_fielddescription = 6

invalid_parameter = 7

undefind_error = 8

double_conversion = 9

stepl_not_found = 10

others = 11.

read table dynfields with key fieldname = 'P_VBELN'.

p_vbeln = dynfields-fieldvalue.

call function 'CONVERSION_EXIT_ALPHA_INPUT'

exporting

input = p_vbeln

importing

output = p_vbeln.

select posnr matnr arktx into table help_item

from vbap

where vbeln = p_vbeln.

call function 'F4IF_INT_TABLE_VALUE_REQUEST'

exporting

retfield = 'POSNR'

dynprofield = 'P_POSNR'

dynpprog = sy-cprog

dynpnr = sy-dynnr

value_org = 'S'

tables

value_tab = help_item.

-


also check this link it will help you

/message/3854825#3854825 [original link is broken]

Regards,

Pavan