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

Creating search help

Former Member
0 Likes
587

I have added a new field to table QMEL, adn this field links to a 'Z' table. So I have created a domain poiting to this table, and a search help whihc passes in the customer number, and then passes back the value for my new field, based on what is held in the 'Z' table. This all works fine.

But then I have aded the new field to the IW51 transaction, and when using the search help in the transaction, the trasaction just returns the full list of options. So how can I get the transaction to pass in the customer number, so that it restrcits the returned list.

4 REPLIES 4
Read only

Former Member
0 Likes
550

Looks like a strange problem........Try giving the search help in the Screen Field attribute.

Test the Search help nature on any selection Screen of your test program and observe the difference.

in the last option........Create a new search help by deleting this and observe the changes, if any.

Read only

Former Member
0 Likes
550

I ended up wirting my own little fucntion module to produce the search help and I used the fucntion module DYNP_VALUES_READ to read the data from the screen that I needed to use as part of the search help

Read only

0 Likes
550

Hi,

I am also getting the same problem. Could u pls send me the FM code wat u used.

I try to create the search help exit , created the FM and using 'DYNP_VALUES_READ ' FM to read screen values but the values are not coming, it is reading the current screen number and program but I want the TCode screen number and program. Could you pls provide me the input parameters for the FM.

Regards,

Srini.

Read only

Former Member
0 Likes
550

My function module is just a copy of FM QMHL_HELP_BELEG_POSITION...

The first thing I do in the PBO is:

PROCESS ON VALUE-REQUEST.

FIELD maktx MODULE maktx_hlp_i10.

THEN..

DATA: BEGIN OF lit_dynpfields OCCURS 100.

INCLUDE STRUCTURE dynpread.

DATA: END OF lit_dynpfields.

DATA: ls_dyname LIKE d020s-prog.

DATA: ls_dynumb LIKE d020s-dnum.

DATA: ls_catalogue TYPE zmm_catalogue.

*--- Bespoked FM to produce search help list (popup) -


CALL FUNCTION 'Z_SKU_DESCRP_SEARCH_HELP'

IMPORTING

i_maktx = maktx

i_catalogue = ls_catalogue

EXCEPTIONS

data_not_found = 1

OTHERS = 2.

IF sy-subrc <> 0.

MESSAGE ID 'Z0' TYPE 'I' NUMBER '000'

WITH 'No materials found'.

ENDIF.

*--- populate other screen fields with data brought back in above step

ls_dyname = 'ZMM_CREATE_CATALOGUE'.

ls_dynumb = sy-dynnr.

  • Ext Desc

lit_dynpfields-fieldname = 'MATNR'.

lit_dynpfields-fieldvalue = ls_catalogue-matnr.

lit_dynpfields-fieldinp = 'X'.

APPEND lit_dynpfields.

CALL FUNCTION 'DYNP_VALUES_UPDATE'

EXPORTING

dyname = ls_dyname

dynumb = ls_dynumb

TABLES

dynpfields = lit_dynpfields

EXCEPTIONS

invalid_abapworkarea = 01

invalid_dynprofield = 02

invalid_dynproname = 03

invalid_dynpronummer = 04

invalid_request = 05

no_fielddescription = 06

undefind_error = 07.