Relating to a field inside serch help exit

Hi!
The serchhelp which was created by me has two
fields.
One field is character field (CHAR030). It is not
a dictionary field which is being in any table
or else.
My question is how can I relate to this field
in the serch help exit. For example to check
what a user has input in this field ?
I have to program some abap code inside
of serch help exit.
Regards
ertas

hi,
how do you bind my mentioned field with this FunctionModule
F4IF_INT_TABLE_VALUE_REQUEST
Rgds
ertas

Similar Messages

  • Serch Help Exits

    Hi,
    How can i write a serch help exits.
    My requirement is to add a serch help exit for kunnr.

    Hi Phani,
    Goto SE11 create a search help, in the search help exit the search help FM name for example (ZMET_DE_INSP_SHELP_EXIT).
    Check the sample code for search help user exit.
    FUNCTION zspa_es_insp_shelp_exit.
    ""Local 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
      IF callcontrol-step = 'SELECT'.
        CLEAR: i_sel, wa_sel, ws_date_from, ws_date_to, ws_year,
               r_inspdt, i_inst, i_inst_name, i_final, wa_inst,
               wa_inst_name, wa_final.
        REFRESH: i_sel, i_inst, i_inst_name, i_final, r_inspdt.
      ENDIF.
      IF callcontrol-step = 'DISP'.
        i_sel[] = shlp-selopt[].
        READ TABLE i_sel INTO wa_sel WITH KEY shlpfield = 'DATE_FROM'.
        IF sy-subrc = 0.
          ws_date_from = wa_sel-low.
        ENDIF.
        READ TABLE i_sel INTO wa_sel WITH KEY shlpfield = 'DATE_TO'.
        IF sy-subrc = 0.
          ws_date_to = wa_sel-low.
        ENDIF.
        READ TABLE i_sel INTO wa_sel WITH KEY shlpfield = 'YEAR'.
        IF sy-subrc = 0.
          ws_year = wa_sel-low.
        ENDIF.
        IF NOT ws_date_from IS INITIAL AND
           NOT ws_year      IS INITIAL.
          PERFORM go_back_years USING     ws_date_from
                                CHANGING  ws_date_from.
          IF NOT ws_date_to IS INITIAL.
            PERFORM go_back_years USING     ws_date_to
                                  CHANGING  ws_date_to.
            r_inspdt-sign   = c_i.
            r_inspdt-option = c_bt.
            r_inspdt-low    = ws_date_from.
            r_inspdt-high   = ws_date_to.
            APPEND r_inspdt.
          ELSE.
            r_inspdt-sign   = c_i.
            r_inspdt-option = c_eq.
            r_inspdt-low    = ws_date_from.
            APPEND r_inspdt.
          ENDIF.
          SELECT aanlage asparte avstelle bzzinspdt
                 INTO TABLE i_inst
                 FROM eanl AS a INNER JOIN zeanl AS b
                 ON aanlage EQ banlage
                 WHERE b~zzinspdt IN r_inspdt.
          IF sy-subrc = 0.
            SELECT vstelle str_erg2 INTO TABLE i_inst_name
                    FROM evbs
                    FOR ALL ENTRIES IN i_inst
                    WHERE vstelle = i_inst-vstelle.
            LOOP AT i_inst INTO wa_inst.
              wa_final-date_from = ws_date_from.
              wa_final-date_to   = ws_date_to.
              wa_final-year      = ws_year.
              wa_final-anlage    = wa_inst-anlage.
              READ TABLE i_inst_name INTO wa_inst_name WITH KEY
                                     vstelle = wa_inst-vstelle.
              IF sy-subrc = 0.
                wa_final-str_erg2  = wa_inst_name-str_erg2.
              ENDIF.
              wa_final-last_insp_date = wa_inst-zzinspdt.
              PERFORM inspdt_plus_years USING     wa_inst-zzinspdt
                                        CHANGING  wa_final-next_inst_date.
              APPEND wa_final TO i_final.
              CLEAR: wa_final, wa_inst, wa_inst_name.
            ENDLOOP.
            LOOP AT i_final INTO wa_final.
              record_tab-string = wa_final.
              APPEND record_tab.
              CLEAR wa_final.
            ENDLOOP.
          ENDIF.
        ENDIF.
      ENDIF.
      CALL FUNCTION 'F4UT_OPTIMIZE_COLWIDTH'
        TABLES
          shlp_tab    = shlp_tab
          record_tab  = record_tab
        CHANGING
          shlp        = shlp
          callcontrol = callcontrol.
    ENDFUNCTION.
    Regards,
    PRakash.

  • How to concatenate fields in Search help exit

    Hi,
    My requirement is i have to create a search help for a field in cj20n transaction.
    when i press f4 on that field i should get a popup of 4 fields from custom table,when user selects any 1 row,
    first 3 field values should be concatenated and appear in screen field . in search hlp i added 1 more field so that i can concatenate
    all 3 field values and place in it.I can use  search help exit so i can concatenate but there are steps like selone,presel etc i am not able to understand .
    I saw some examples in wiki, but not able to understand what to do for my requirement.
    regards.
    Edited by: vnamamala on May 27, 2010 12:22 PM

    You would use the step 'SELECT' to control the data selection into an internal table.  You would use the step 'DISP' to map the records in the internal table to the search help record table.  In your case, I would already have a field in the internal table with the values concatenated together prior to the hit list display (do this in SELECT step) which is not displayed in the hit list but is flagged as the EXPORT field in the search help definition; otherwise just put the field at the end of the hit list. 
    Map your results in DISP as follows:
    *   Map the internal table to RECORD_TAB
        CALL FUNCTION 'F4UT_RESULTS_MAP'
             TABLES
                  SHLP_TAB          = SHLP_TAB
                  RECORD_TAB        = RECORD_TAB
                  SOURCE_TAB        = GT_DOCUMENT
             CHANGING
                  SHLP              = SHLP
                  CALLCONTROL       = CALLCONTROL
             EXCEPTIONS
                  ILLEGAL_STRUCTURE = 1
                  OTHERS            = 2.
        CALL FUNCTION 'F4UT_OPTIMIZE_COLWIDTH'
             TABLES
                  SHLP_TAB    = SHLP_TAB
                  RECORD_TAB  = RECORD_TAB
             CHANGING
                  SHLP        = SHLP
                  CALLCONTROL = CALLCONTROL.

  • Modify va01 fields in search help exit.

    I have implemented the search help exit for Ship to field , based upon the values of ship to field , I need to modify the Sold to field during Sales Order creation.
    Can this be achieved ? If yes how ?
    Ajay

    Hi Ajay ,
    1.     go to ship to party data element KUNAG as below:
    And assign shearch(NEW) help name: Z_KUNNR
                                            Parameters : CUS
    2.     then create search helps:-
    2.1.     Search help name : Z_KUNNR(any name as per your standerd)
    2.2.     Short Text : Search Help for Kunnr.
    2.3.     Search Help Exit : Z_sold_to_party_F4HELP_EXIT(Fuction Module)
    2.4.     Other Attributes of Search help are as follows:
    Search help parameters:
         CUS  TYPE  kunnr , DESCRIPTION  TYPE     BEZEI40 .
    SPOS (Selection Position)     NA
    LPOS (Listing Position)     CUS  --  1,       
                                                    DESCRIPTION -- 2.
    Export Parameter     CUS .
    Import Parameter     NA
    Dialog Type     Display Values Immediately.
    Selection Method     NA
    2.5.     2. Create fuction module: Z_sold_to_party_F4HELP_EXIT Below are the details of the Function Module Attributes, Import , Export and Changing Parameters, Tables and global data (Goto -> Global Data )
    Proceesing Type:      Normal Function Module,                
    Start Immediate.
    Edit Lock     NA
    Global Data     TABLES:  specify the table from where you are going to get the Sold to party values
    Import Parameters      NA
    Export Parameters      NA
    Changing Parameters        SHLP          TYPE     SHLP_DESCR_T,
                                                CALLCONTROL  LIKE     DDSHF4CTRL,
    Pass value (Check Box ) Checked for both Parameters.
    Tables      SHLP_TAB       TYPE SHLP_DESCR_TAB_T,
    RECORD_TAB       LIKE     SEAHLPRES,
    2.6.     
    2.7.     Source code Logic Implementation :-
                   Select the sold to party value from table into struct_record_tab-string .
                   Aftere that goto user exit FORM USEREXIT_MOVE_FIELD_TO_VBAK or
    FORM                                                             USEREXIT_SAVE_DOCUMENT_PREPARE.
                  And add logic to assign sold to party value to the value to ship to party
    Thanks and Regards,
    Pavan

  • USE OF SERCH HELP EXIT

    hello
    i am usin serch help in callcontrol = 'DISP'
    in this way
    LOOP AT GT_IT_ITAB INTO  GW_ITAB.
         LWA_SELOPT-SHLPNAME     = 'ZSDH_FOCUS_LIST'.
         LWA_SELOPT-SHLPFIELD    = 'AUART'.
         LWA_SELOPT-SIGN         = 'I'.
         LWA_SELOPT-OPTION       = 'EQ'.
         LWA_SELOPT-LOW          = GW_ITAB-PARAM_VALUE2.
         APPEND LWA_SELOPT TO LT_SELOPT.
       ENDLOOP.
       SHLP-SELOPT[] = LT_SELOPT[].
    what is missing becouse im getting worg aswer
    thank you
    for your help
    shlomit

    hello
    i am usin serch help in callcontrol = 'DISP'
    in this way
    LOOP AT GT_IT_ITAB INTO  GW_ITAB.
         LWA_SELOPT-SHLPNAME     = 'ZSDH_FOCUS_LIST'.
         LWA_SELOPT-SHLPFIELD    = 'AUART'.
         LWA_SELOPT-SIGN         = 'I'.
         LWA_SELOPT-OPTION       = 'EQ'.
         LWA_SELOPT-LOW          = GW_ITAB-PARAM_VALUE2.
         APPEND LWA_SELOPT TO LT_SELOPT.
       ENDLOOP.
       SHLP-SELOPT[] = LT_SELOPT[].
    what is missing becouse im getting worg aswer
    thank you
    for your help
    shlomit

  • Serch Help Exit problem

    Hi.
    I have this FM created by me.
    FUNCTION z_ricerca_ara_ofi.
    *"*"Interfaccia locale:
    *"  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
    DATA DECLARED ... :P
    * EXIT immediately, if you do not want to handle this step
      IF callcontrol-step <> 'SELONE' AND
         callcontrol-step <> 'SELECT' AND
         " AND SO ON
         callcontrol-step <> 'DISP'.
        EXIT.
      ENDIF.
    * STEP SELONE  (Select one of the elementary searchhelps)
    * This step is only called for collective searchhelps. It may be used
    * to reduce the amount of elementary searchhelps given in SHLP_TAB.
    * The compound searchhelp is given in SHLP.
    * If you do not change CALLCONTROL-STEP, the next step is the
    * dialog, to select one of the elementary searchhelps.
    * If you want to skip this dialog, you have to return the selected
    * elementary searchhelp in SHLP and to change CALLCONTROL-STEP to
    * either to 'PRESEL' or to 'SELECT'.
      IF callcontrol-step = 'SELONE'.
    *   PERFORM SELONE .........
        EXIT.
      ENDIF.
    * STEP PRESEL  (Enter selection conditions)
    * This step allows you, to influence the selection conditions either
    * before they are displayed or in order to skip the dialog completely.
    * If you want to skip the dialog, you should change CALLCONTROL-STEP
    * to 'SELECT'.
    * Normaly only SHLP-SELOPT should be changed in this step.
      IF callcontrol-step = 'PRESEL'.
    *   PERFORM PRESEL ..........
        EXIT.
      ENDIF.
    * STEP SELECT    (Select values)
    * This step may be used to overtake the data selection completely.
    * To skip the standard seletion, you should return 'DISP' as following
    * step in CALLCONTROL-STEP.
    * Normally RECORD_TAB should be filled after this step
      IF callcontrol-step = 'SELECT'.
        LOOP AT shlp-selopt INTO ls_interface.
          APPEND ls_interface TO lt_interface.
        ENDLOOP.
        STUFF DONE HERE :P.
        LOOP AT lt_matnr INTO ls_matnr.
          APPEND ls_matnr TO record_tab.
        ENDLOOP.
      ENDIF.
    * STEP DISP     (Display values)
    * This step is called, before the selected data is displayed.
    * You can e.g. modify or reduce the data in RECORD_TAB
    * according to the users authority.
    * If you want to get the standard display dialog afterwards, you
    * should not change CALLCONTROL-STEP.
    * If you want to overtake the dialog on you own, you must return
    * the following values in CALLCONTROL-STEP:
    * - "RETURN" if one line was selected. The selected line must be
    *   the only record left in RECORD_TAB. The corresponding fields of
    *   this line are entered into the screen.
    * - "EXIT" if the values request should be aborted
    * - "PRESEL" if you want to return to the selection dialog
      IF callcontrol-step = 'DISP'.
    *   PERFORM AUTHORITY_CHECK TABLES RECORD_TAB USING SHLP.
        EXIT.
      ENDIF.
    ENDFUNCTION.
    My questions is:
    Do i have to write something else in some of the STEPS ?
    Because i receive the message that the list is empty, but lt_matnr has 397 lines.
    I saw that in some further steps, outside my FM, record_tab is refreshed.
    There seams to be something missing from my FM, but i can't figure it out.
    Can someone help?
    Thanks.

    Hi there guys.
    Thanks for the help and for the ideas.
    The answer was allot simpler. It was only needed to add one line
    callcontrol-step = 'DISP'.
    before the corresponding ENDIF of
    IF callcontrol-step = 'SELECT'.
    Here is what I did:
    FUNCTION z_ricerca_ara_ofi.
    *"*"Interfaccia locale:
    *"  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
      DATA: BEGIN OF ls_cawnt,
            atinn TYPE atinn,
            spras TYPE spras,
            adzhl TYPE adzhl,
            atzhl TYPE atzhl,
            END OF ls_cawnt.
      DATA: BEGIN OF ls_cawn,
            atwrt TYPE atwrt,
            atflv TYPE atflv,
            END OF ls_cawn.
      DATA: BEGIN OF ls_cabn,
            atfor TYPE atfor,
            anzst TYPE anzst,
            anzdz TYPE anzdz,
            END OF ls_cabn.
      DATA: BEGIN OF lt_ausp OCCURS 0,
            objek TYPE objnum,
            cuobf     TYPE cuobm,
            END OF lt_ausp,
            ls_ausp LIKE LINE OF lt_ausp.
      DATA: lt_interface TYPE STANDARD TABLE OF ddshselopt,
            ls_interface LIKE LINE OF lt_interface,
            strwhere TYPE string,
            strwhere2 TYPE string
      TYPES: BEGIN OF gs_matnr,
              matnr TYPE matnr,
             END OF gs_matnr.
      DATA: lt_matnr TYPE TABLE OF gs_matnr,
            ls_matnr TYPE gs_matnr.
      DATA: BEGIN OF s_matnr OCCURS 0,
             sign(1),
             option(2),
             low  TYPE matnr,
             high TYPE matnr,
            END OF s_matnr.
      DATA: BEGIN OF s_maktg OCCURS 0,
             sign(1),
             option(2),
             low  TYPE maktg,
             high TYPE maktg,
            END OF s_maktg.
      DATA: BEGIN OF s_spras OCCURS 0,
             sign(1),
             option(2),
             low  TYPE spras,
             high TYPE spras,
            END OF s_spras.
      DATA: BEGIN OF s_zzcodara OCCURS 0,
             sign(1),
             option(2),
             low  TYPE zzcodara,
             high TYPE zzcodara,
            END OF s_zzcodara.
      DATA: BEGIN OF s_zzcodofi OCCURS 0,
             sign(1),
             option(2),
             low  TYPE zzcodofi,
             high TYPE zzcodofi,
            END OF s_zzcodofi.
      DATA: BEGIN OF s_carat1 OCCURS 0,
            sign(1),
            option(2),
            low  TYPE zcarat,
            high TYPE zcarat,
           END OF s_carat1.
      DATA: BEGIN OF s_carat2 OCCURS 0,
            sign(1),
            option(2),
            low  TYPE zcarat,
            high TYPE zcarat,
           END OF s_carat2.
      DATA: BEGIN OF s_carat3 OCCURS 0,
            sign(1),
            option(2),
            low  TYPE zcarat,
            high TYPE zcarat,
           END OF s_carat3.
      DATA: BEGIN OF s_categ OCCURS 0,
            sign(1),
            option(2),
            low  TYPE zcateg,
            high TYPE zcateg,
           END OF s_categ.
    * EXIT immediately, if you do not want to handle this step
      IF callcontrol-step <> 'SELONE' AND
         callcontrol-step <> 'SELECT' AND
         " AND SO ON
         callcontrol-step <> 'DISP'.
        EXIT.
      ENDIF.
    * STEP SELONE  (Select one of the elementary searchhelps)
    * This step is only called for collective searchhelps. It may be used
    * to reduce the amount of elementary searchhelps given in SHLP_TAB.
    * The compound searchhelp is given in SHLP.
    * If you do not change CALLCONTROL-STEP, the next step is the
    * dialog, to select one of the elementary searchhelps.
    * If you want to skip this dialog, you have to return the selected
    * elementary searchhelp in SHLP and to change CALLCONTROL-STEP to
    * either to 'PRESEL' or to 'SELECT'.
      IF callcontrol-step = 'SELONE'.
    *   PERFORM SELONE .........
        EXIT.
      ENDIF.
    * STEP PRESEL  (Enter selection conditions)
    * This step allows you, to influence the selection conditions either
    * before they are displayed or in order to skip the dialog completely.
    * If you want to skip the dialog, you should change CALLCONTROL-STEP
    * to 'SELECT'.
    * Normaly only SHLP-SELOPT should be changed in this step.
      IF callcontrol-step = 'PRESEL'.
    *   PERFORM PRESEL ..........
        EXIT.
      ENDIF.
    * STEP SELECT    (Select values)
    * This step may be used to overtake the data selection completely.
    * To skip the standard seletion, you should return 'DISP' as following
    * step in CALLCONTROL-STEP.
    * Normally RECORD_TAB should be filled after this step
      IF callcontrol-step = 'SELECT'.
        LOOP AT shlp-selopt INTO ls_interface.
          APPEND ls_interface TO lt_interface.
        ENDLOOP.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'MATNR'.
        IF sy-subrc = 0.
          s_matnr-sign = ls_interface-sign.
          s_matnr-option = ls_interface-option.
          s_matnr-low = ls_interface-low.
          APPEND s_matnr.
          CONCATENATE strwhere ' mara~matnr IN s_matnr AND' INTO strwhere.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'MAKTG'.
        IF sy-subrc = 0.
          s_maktg-sign = ls_interface-sign.
          s_maktg-option = ls_interface-option.
          s_maktg-low = ls_interface-low.
          APPEND s_maktg.
          CONCATENATE strwhere ' MAKTG IN s_maktg AND' INTO strwhere.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'SPRAS'.
        IF sy-subrc = 0.
          s_spras-sign = ls_interface-sign.
          s_spras-option = ls_interface-option.
          s_spras-low = ls_interface-low.
          APPEND s_spras.
          CONCATENATE strwhere ' spras IN s_spras AND' INTO strwhere.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'ZZCODARA'.
        IF sy-subrc = 0.
          s_zzcodara-sign = ls_interface-sign.
          s_zzcodara-option = ls_interface-option.
          s_zzcodara-low = ls_interface-low.
          APPEND s_zzcodara.
          CONCATENATE strwhere ' zzcodara IN s_zzcodara AND' INTO strwhere.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'ZZCODOFI'.
        IF sy-subrc = 0.
          s_zzcodofi-sign = ls_interface-sign.
          s_zzcodofi-option = ls_interface-option.
          s_zzcodofi-low = ls_interface-low.
          APPEND s_zzcodofi.
          CONCATENATE strwhere ' zzcodofi IN s_zzcodofi AND' INTO strwhere.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'CARAT1'.
        IF sy-subrc = 0.
          s_carat1-sign = ls_interface-sign.
          s_carat1-option = ls_interface-option.
          s_carat1-low = ls_interface-low.
          APPEND s_carat1.
          CONCATENATE strwhere2 ' ATWTB IN s_carat1 AND' INTO strwhere2.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'CARAT2'.
        IF sy-subrc = 0.
          s_carat2-sign = ls_interface-sign.
          s_carat2-option = ls_interface-option.
          s_carat2-low = ls_interface-low.
          APPEND s_carat2.
          CONCATENATE strwhere2 ' ATWTB IN s_carat2 AND' INTO strwhere2.
          CLEAR ls_interface.
        ENDIF.
        READ TABLE lt_interface INTO ls_interface WITH KEY shlpfield = 'CARAT3'.
        IF sy-subrc = 0.
          s_carat3-sign = ls_interface-sign.
          s_carat3-option = ls_interface-option.
          s_carat3-low = ls_interface-low.
          APPEND s_carat3.
          CONCATENATE strwhere2 ' ATWTB IN s_carat3 AND' INTO strwhere2.
          CLEAR ls_interface.
        ENDIF.
        IF ( NOT strwhere2 IS INITIAL ).
          SHIFT strwhere2 RIGHT DELETING TRAILING 'AND'.
          SELECT SINGLE atinn spras adzhl atzhl
          FROM cawnt
          INTO CORRESPONDING FIELDS OF ls_cawnt
          WHERE (strwhere2).
          SELECT SINGLE atwrt atflv
          FROM cawn
          INTO CORRESPONDING FIELDS OF ls_cawn
          WHERE atinn EQ ls_cawnt-atinn
            AND atzhl EQ ls_cawnt-atzhl.
          SELECT SINGLE atfor anzst anzdz
          FROM cabn
          INTO CORRESPONDING FIELDS OF ls_cabn
          WHERE atinn EQ ls_cawnt-atinn
            AND adzhl EQ ls_cawnt-adzhl.
          IF ls_cabn-atfor = 'CHAR'.
            SELECT objek
            FROM ausp
            INTO CORRESPONDING FIELDS OF TABLE lt_ausp
            WHERE atinn EQ ls_cawnt-atinn
              AND adzhl EQ ls_cawnt-adzhl
              AND atwrt EQ ls_cawn-atwrt.
          ENDIF.
          IF ls_cabn-atfor = 'NUM'.
            SELECT objek
            FROM ausp
            INTO CORRESPONDING FIELDS OF TABLE lt_ausp
            WHERE atinn EQ ls_cawnt-atinn
              AND adzhl EQ ls_cawnt-adzhl
              AND atflv GE ls_cawn-atflv
              AND atflb LE ls_cawn-atflv.
          ENDIF.
          LOOP AT lt_ausp INTO ls_ausp.
            MOVE ls_ausp-objek+0(18) TO ls_ausp-cuobf.
            MODIFY lt_ausp INDEX sy-tabix FROM ls_ausp
                   TRANSPORTING cuobf.
          ENDLOOP.
          IF sy-subrc = 0.
            SELECT matnr
            FROM mara
            INTO CORRESPONDING FIELDS OF TABLE lt_matnr
            FOR ALL ENTRIES IN lt_ausp
            WHERE cuobf EQ lt_ausp-cuobf.
          ENDIF.
        ENDIF.
        SHIFT strwhere RIGHT DELETING TRAILING 'AND'.
        IF NOT s_matnr-low IS INITIAL.
          SELECT mara~matnr
          FROM mara
                JOIN makt ON mara~matnr = makt~matnr
          INTO CORRESPONDING FIELDS OF TABLE lt_matnr
          WHERE (strwhere) " mara~prdha IN s_categ AND spras IN s_spras "
        ENDIF.
        LOOP AT lt_matnr INTO ls_matnr.
          APPEND ls_matnr TO record_tab.
        ENDLOOP.
        callcontrol-step = 'DISP'.
        CLEAR s_categ.
        CLEAR lt_matnr. REFRESH lt_matnr.
        CLEAR ls_matnr.
      ENDIF.
    * STEP DISP     (Display values)
    * This step is called, before the selected data is displayed.
    * You can e.g. modify or reduce the data in RECORD_TAB
    * according to the users authority.
    * If you want to get the standard display dialog afterwards, you
    * should not change CALLCONTROL-STEP.
    * If you want to overtake the dialog on you own, you must return
    * the following values in CALLCONTROL-STEP:
    * - "RETURN" if one line was selected. The selected line must be
    *   the only record left in RECORD_TAB. The corresponding fields of
    *   this line are entered into the screen.
    * - "EXIT" if the values request should be aborted
    * - "PRESEL" if you want to return to the selection dialog
      IF callcontrol-step = 'DISP'.
    *    PERFORM authority_check TABLES record_tab shlp_tab
    *                               CHANGING shlp callcontrol.
    *    EXIT.
      ENDIF.
    ENDFUNCTION.
    It's true that it was not obligatory to do something in that perform (that's why it's still commented), but still I did not have to change the name in F4UT*.
    If there is a special reason i have to change it in F4UT* pls tell me.
    Thanks again for you help.
    Edited by: Marius Cosmin Stoica on Aug 19, 2008 8:13 PM

  • What is the significance of data collection nad search help exit field ?

    Dear Gurus
    I  know i am asking very basic quetion of abap but sdn is  the only source to learn sap for me.I want to thanks you all for your kind support.
    i read  most of the post related to search help and trying to create one.
    for elementary search help.
    SE11 -> SEACH HELP -> ELEMENTARY SEARCH HELP
    I have doubts regarding to fields "DATA COLLECTION" and "SEARCH HELP EXIT".
    reference to a  tutorial it is a maintenance view  shall i  have to reate  a maintenace view first.
    and other field is  SEARCH HELP EXIT what is this.
    please help me .
    Thanks in advance.
    Chitta Ranjan mahato.
    Edited by: chitto123 on Oct 8, 2010 5:59 AM

    Howdy,
    DATA COLLECTION - refers to a database table or view.  This is the data that the search help will search through and display based on the parameters provided, so you can create your own view for the search help if you want the search to cover multiple tables.
    SEARCH HELP EXIT - You can create a function module to be able to alter the Search Help's selection and results at various events throughout the search help.  An example of this function module is provided with some documentation in function module F4IF_SHLP_EXIT_EXAMPLE.
    Cheers
    Alex

  • Question about searh help exit

    Hi all
    Can we implement our owen serch help exit , for instance Z_SHL_EXIT, and put it in the search help exit og the sap standar search help , in order to change its behavior or to call another search help.
    let say that sap has a search help called CRAMA , but I want to delete some fields and add an extra field to it , then I can create an Z_CRAMA based on CRAMA after my requirement .
    I can not change the way of calling the CRAMA  and call Z_CRAMA.
    Now , would I be able from CRAMA SEARCH HELP EXIT call Z_CRAMA searh help and use it.
    Thanks in advance.

    For the particular field you have in mind, how is the elementary search help accessed?  Directly or via one of the collective search helps?  If via one of the collective search helps, you would be better off copying CRAMA, modifying it, then including it as an additional elementary search help with it's own title to differentiate it.  Once the users start using it, it will be the default tab that shows up first in the collective help.

  • Passing two export parameter from search help exit

    hi gurus,
    i need your help
    i need  to import two field from search help exit into two screen field.
    eg.
    parameters : p1 type p1 matchcode id s1,
                        p2 type p2,
    on f4 for p1 i am displaying two field in search help output, p1 and p2.
    i am using search help exit FM to pass value from s1, not using any view or table infact extracting data using other function module. i am filling.
    what i want , when i make a selection on f4 for p1, p2 should also be filled from the same search help s1.
    i allready tried memory id-export option in my search help exit at RETURN event but that does not fits well.
    ASAP reply higly appreciated
    will reward point for sure

    thanks a lot it worked out by defining search help for structure which contain these two fields.
    what i was missing was interface link.
    mandy

  • Customer field account assignment - F4 - search help exit

    Hi all,
    I have a question with regard to a F4 search help exit I'm try to build for a new CUF in the account assignment (include INCL_EEW_PD_ACC_CSF).
    I've successfully created everything (search help + F4 search exit (read R/3 table)), but when I want to include restricted the search with certain filter values entered on the screen I'm stuck.
    I tried to achieve this by passing the parameters entered on the search screen to the RFC read table function, but in fact I'm not able to read the <b>screen values</b> (using 'DYNP_VALUES_READ'):
    CALL FUNCTION 'DYNP_VALUES_READ'
            EXPORTING
              dyname               = lc_dyname_1
              dynumb               = lc_dynumb_1
              translate_to_upper   = 'X'
            TABLES
              dynpfields           = li_fields_filter
    I'm always getting an invalid dynpro error (I've tried passing SAPLBBP_PDH_ACC, SAPLBBP_SC_UI_ITS, SAPLBBP_CUF,...).
    Does anybody know how I can include de filter values of my search screen in my search ?
    Thanks in advance,
    Kristof

    Hi
    Which SRM version are you using ? What's your detailed requirement ?
    <b>You need to call these function modules inside your search help exit to fetch the user-entered value and then process it accordingly as per your requirements.</b>
    <u>Please go through these function modules.</u>
    *--- Get the user-entered fieldname
    <u>    CALL FUNCTION 'F4UT_PARAMETER_VALUE_GET'</u>
    *--- Map the Results
    <u>    CALL FUNCTION 'F4UT_RESULTS_MAP'</u>
    <b>Other related links -></b>
    Re: Search helps - CASE sensitive
    Re: Search Help - format problem
    Hope this will help.
    Regards
    - Atul

  • Adding a new field to the search help exit

    Hi friends,
    adding a new field to the search help exit. How does it work ?
    Thanks in advace
    Ilhan

    The search help exit allows you to modify functionality of search help. If you add a new field to the
    parameter list that is not contained on the selection method you can manually populate it within the search
    help exit.
    This  would be performed within the u2018STEP DISPu2019 section. Once within this section all search help
    data has been retrieved and is stored in table RECORD_TAB (record_tab-string) as one long string value.
    Therefore you need to read table SHLP in-order to locate position of value within string.
    Example:
    To find position of personnel number (PERNR) within elemenory search
    help M_PREMN you would use the following code:
    Loop at record_tab.
         read table shlp-fielddescr into wa_shlp
                                       with key tabname   = 'M_PREMN'
                                                fieldname = 'PERNR'.
    You could then use this information in the following way, for
    example, to find a persons organisation unit:
          select  orgeh endda
            up to 1 rows
            from pa0001
            into (ld_orgeh,ld_endda)
           where pernr eq record_tab-string+wa_shlp-offset(8)
                                                      u201Cpernr length is 8
           order by endda descending.
          endselect.
          select single orgtx
            from t527x
            into ld_orgtxt
           where orgeh eq ld_orgeh and
                 sprsl eq sy-langu and
               ( endda ge sy-datum and
                 begda le sy-datum ).
    If you have added a new field to the end of the parameters list
    the next step is to populate it by adding this data to the end of
    the record_tab string:
      concatenate record_tab-string ld_orgtxt into record_tab-string.
      modify record_tab.
    endloop.

  • Modify another field value in search help exit.

    While creating the Sales Order, the user does an f4 on ship to party to determine the sold to party ( search help exit ), now I have the values of both the Ship to customer and Sold to customer in the search help exit, but I can update only the ship to field of the sales order, do you know how I can modify the sold to value on the screen.
    I tried setting up the parameter id 'VAG' in the search help exit with the determined value, but this value is not getting copied in the Sold to party field once the search help is executed.
    The other option which is left is export to memory and import to memory in another user exit of VA01. Is there any other alternative? Also which program do I need to do the import of memory so that sold to party is displayed on the initial before saving the document ?
    Ajay

    Hi,
    Yes..Try calling from the search help exit..
    You have to pass the program name and screen number..
    In the internal table parameter DYNPFIELDS..
    Pass the fieldname and fieldvalue...
    Thanks,
    Naren

  • Serach help  exit (vendor NAME1 field)

    Hi friends,
    I have developed a search for vendor number using a custom view.
    In view I am parameter for name. In case vendor if I gives lower case details if I specifiy lowrcase value (e.g. test) and gives only uppercase value for in case uppercase values (TEST). I know it is happing becasue of lower option is ticked on domain of NAME1 field.
    I want to get both uppercase and lowercase values irespective of input is uppercase or lowercase.
    Is it possible to elminate the restriction using serach help exit?
    Regards,
    Amit R.

    Hi,
    I used MCOD1 field in Search help for field refernce to NAME1 field.
    Thanks and regards,
    Amit R.

  • Search help exit for field name: BANKL (bank number)

    Is there any search exit that can be used on field BANKL to display only some bank based on user defined criteria?
    Regards

    we can create the search help ..
    we dont need to use CMOD or SMOD for this .
    The search help exit are implemented as function module (newly created) . 
    The place for exit in search help is blank but we can assing our exit ( FM created ) into that . Take the F1 help of that in change mode of search help .
    A search help exit is a function module for making the input help process described by the search help more flexible than possible with the standard version.
    This function module must have the same interface as function module F4IF_SHLP_EXIT_EXAMPLE. The search help exit may also have further optional parameters (in particular any EXPORTING parameters).
    A search help exit is called at certain timepoints in the input help process.
    Note: The source text and long documentation of the above-specified function module (including the long documentation about the parameters) contain information about using search help exits.
    Function modules are provided in the function library for operations that are frequently executed in search help exits. The names of these function modules begin with the prefix F4UT_. These function modules can either be used directly as search help exits or used within other search help exits. You can find precise instructions for use in the long documentation for the corresponding function module.
    well  which search help you want to change. and what changes are needed .?

  • Anyone can Help on {suppress} [database fields] inside the [fields]

    Reason to put database fields inside the fields
    1. I put in (word and database fields) inside fields box in order to let my word display smoothly one by one.
    Problem is , i am in section report footer d, i plan to suppress {Qrev if the value is "AAA"}
    got this type of function?
    If the Qrev = "AAA" than  suppress/hide it.
    Design screen :
    We will the undersigned, hereby acknowledge my acceptance of the above quote and agreed to the rates, terms and conditions stated herein as per your reference no: {QRef}  dates
    Display screen=
    We will the undersigned, hereby acknowledge my acceptance of the above quote and agreed to the rates, terms and conditions stated herein as per your reference no: 2014    AAA dates 10 march 2009
    wanted display screen
    We will the undersigned, hereby acknowledge my acceptance of the above quote and agreed to the rates, terns and conditions stated herein as per your reference no: 2014   dates 10 march 2009

    As what u say, i try to key in a [formula fields] call Qrev
    here the code :
    if {Quotation.QRev} = "AAA" then
        {Quotation.QRev} = " "
    We will the undersigned, hereby acknowledge my acceptance of the above quote and agreed to the rates,
    terns and conditions stated herein as per your reference no: MKT-2009/05/0018 True dates 19 Jun 2009
    but the Qrev.wouldnt be go delete / as a blank value. The value will only become  true or false
    Edited by: chee85 on Sep 18, 2009 7:40 AM

Maybe you are looking for