2010 Dec 02 12:58 PM
Hi at all,
how can i change the data elemte of an parameter in the search help?
The selektion method of the search help is a view and the data element comes from the DB.
Maybe it is possible to change the length of the parameter in the result list? That would help, too!
Thanks in advance.
Regards
2010 Dec 02 1:29 PM
Hi,
try to create your own search help. You can use AT SELECTION-SCREEN ON VALUE-REQUEST event the FM F4IF_INT_TABLE_VALUE_REQUEST.
Regards,
Rodrigo
2010 Dec 02 1:29 PM
Hi,
try to create your own search help. You can use AT SELECTION-SCREEN ON VALUE-REQUEST event the FM F4IF_INT_TABLE_VALUE_REQUEST.
Regards,
Rodrigo
2010 Dec 02 1:55 PM
Hi Rodrigo,
can you please specify your answer! i already use my own search.
I also thought about implementing a search help exit, additonal to the view.
Is that the only way changing the parameter length?
2010 Dec 02 4:43 PM
Alexander,
see this code bellow:
REPORT zsearch.
TYPES:
BEGIN OF ty_scustom,
id TYPE scustom-id,
name(8) TYPE c,
END OF ty_scustom.
DATA: wa_scustom TYPE ty_scustom.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-002.
SELECT-OPTIONS s_name FOR wa_scustom-name NO INTERVALS OBLIGATORY.
SELECTION-SCREEN END OF BLOCK b1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_name-low.
PERFORM f_select.
*&---------------------------------------------------------------------*
*& Form f_select
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
FORM f_select.
TYPES: BEGIN OF ty_data,
name TYPE scustom-name,
END OF ty_data.
DATA: tl_data TYPE STANDARD TABLE OF ty_data,
wl_data TYPE ty_data,
tl_return TYPE STANDARD TABLE OF ddshretval,
wl_return TYPE ddshretval.
SELECT name
FROM scustom
INTO TABLE tl_data.
CHECK sy-subrc = 0.
SORT tl_data BY name.
DELETE ADJACENT DUPLICATES FROM tl_data COMPARING name.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
* DDIC_STRUCTURE = ' '
retfield = 'NAME'
value_org = 'S'
TABLES
value_tab = tl_data
* FIELD_TAB =
return_tab = tl_return
EXCEPTIONS
parameter_error = 1
no_values_found = 2.
IF sy-subrc = 0.
READ TABLE tl_return INDEX 1 INTO wl_return.
CHECK sy-subrc = 0.
s_name-low = wl_return-fieldval.
ENDIF.
ENDFORM. "f_select
Is it helpful? In search help show full name, but in parameter, only 8 first chars. Is it what you want to do?
Regards,
Rodrigo
2010 Dec 14 8:52 AM
Hi Rodrigo.
My answer comes very late, i'm sory.
Its not really what i was looking for. Maybe the explanation of the problem was wrong.
However, i've solved it and your hint was helpful anyway.
Thanks
2010 Dec 14 8:56 AM
i solved the problem with a search help exit. i've changed the length of the parameters in shlp. (shlp-fielddescr)
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |