"F4" search-help for custom field in PCUI

Hello all,
Does anyone know how I can create my own simple F4-help for a custom field I have added to a custom Tab Page in the PCUI? It should show a selection from a custom table.
I couldn't find an useable example in the PCUI-cookbook.
Any ideas anyone?
Kind regards,
Martijn de Jong.

Hi Manuel,
I saw that paragraph but didn't know how to implement it. Maybe you or someone else can explain/translate in steps what I have to do, according to the text underneath, i want to use a combobox:
"If you want the application to specify the values for selection (within popup or dropdown list box or
combobox (COBX respectively TIME)) at runtime instead of using predefined domain values, data
must be provided by the application via the method FILL_DROPDOWN_LISTBOX. That scenario
works if the field type is "Input Field" and the F4 application is set to "VALUE_TABLE". With these
customizing settings, the method FILL_DROPDOWN_LISTBOX of the interaction layer is called at
runtime and the actual field values will be passed to the application via importing parameter
IT_SCREEN_STRUCTURE. Thus the application can provide context-sensitive help values within a
popup or a dropdown list box respectively combobox (COBX respectively TIME). Within the popup
more than one column of values can be displayed."
How/where do I (re)define method FILL_DROPDOWN_LISTBOX? Do i have to maintain an own class? and how do i ensure that more columns are shown?
Kind regards,
Martijn de Jong.

Similar Messages

  • Search Help for Custom field in Sourcing Cockpit

    Hi SRM Experts,
    I added custom field "rush order" in the Structures as per requirement. I added code in MODIFY_SCREEN function module. Search help is working for "rush order" in Process Purchase Orders (to search PO) and Check Status (Searching Shopping Cart). But it is not working in sourcing cockpit. Please guide or suggest me is there any additional settings or programming is required to have search help for custom fields in Sourcing Cockpit.
    Thanks a lot in advance.
    Thanks,
    Koyya

    Hi SRM Experts,
    Please let me know any suggestion on this issue.
    Thanks a lot in advance.
    Thanks,
    Koyya

  • No search help for Custom field ZZKUKLA in vk11

    Hi,
    I have added the field KUKLA - Customer classification as a pricing field in KOMP. Created an access sequence as follows: Sales Org.-> Customer Classification - material group.
    In the creation of the record in VK11 I'm not getting the search help for the ZZKUKLA field. The thing is that if I'm in change or display, the search help for the field appears and lists the possible values.
    Anyone have a clue?
    Thanks!
    /Patrik

    Dear Pratik,
    Request you to first add Customer classification field (ZZKUKLA) in KOMK structure insted of structure KOMP. Becasue it is header structure filed. After add this new filed in KOMK structure, Add this new filed in your field catelog and than create table and new access sequence. Also request you to select KOMK structure in your access sequence against this new field Customer classification ZZKUKLA.
    Regards,
    Haresh Panara

  • Search help for custome field with different data type

    Hi Friends,
    I have Created a  custom table in which i have created a field is
    ZMATLONG which stores material number.
    Now the data element is zdmat which is of char 40..
    Now i want to give search help for this field ZMATLONG..
    I have tried many ways giving search help to this field
    a) i Tried to attach the standard search help of MATNR ie : MAT1 but its showing me data type inconsistancy
    b) i created a zsearch help and in the selection method i have used database table mara , again here iam getting the same error data type inconsistancy...
    Now how can i give the search help like matnr field to my custom field ZMATLONG...
    How can i do it..?
    Thanks in Advance..
    Regards
    Kumar

    Hi,
    MATNR ahs length 18 and ZMATLONG has length 40.So due to this u cannot use MAT1 search help.
    best way would be cope MAT1 into Z search help. Then in the search help parameter change the data element of field
    MATNR as ZMATLONG.
    Now if you assign Z search help to ZMATLONG  it will work.
    I tried this its working fine.
    Shanmugavel Chandrasekaran

  • Search help for custom field in SRM

    Hi All,
    Im new to abap. I want to add(enhancement) custom input field with search help function for organization unit. I hv added input field and its displaying in portal also.
    Now i want to add f4 help. Can u please help me in this regard. Can u tell me the steps to do for adding f4 help.
    Thanks,
    Rani.

    add search help to input fields data type. or you could assign search help via structure there that field is defined. you could enhance standard code adding custom search help which is called via FM. Choose the way.
    best regards,
    dez_

  • Search help for customer field.

    Hi all,
    I have one select option on company code :  bukrs
    and  one on    customer number : kunnr
    i want search help for <b>kunnr</b> which should be based on bukrs.
    can any guide me how to do it.
    any suggestion will be rewarded.
    Regards
    cnu

    Table KNB1.
    Rob

  • Search help for custom fields added through BADI_FDCB_SUBBAS04

    Hi guys
    I have two cutom fields on basic data screen that i have added using an implementation of the BADI
    BADI_FDCB_SUBBAS04
    I want to use the value entered in one of the fields as a import parameter in another fiields search help.  On value request the structure INVFO contains the other data entered on screen in the basic data screen however my custom fields appear empty. 
    However if i press enter and request values again the search help will pop up correctly.  Is there a way i can avoid having to press enter before i can get my values??
    regards
    Isaac Prince

    Hi guys
    I have not found any notes/texts regarding my issue however i think with some user training/re-orientation the small issue will go away.
    regards
    Isaac Prince

  • How to assign search help for custom cost centre field in SRM 7.0

    Hi Experts!!
    We are currently working in SRM 7.0.As per our business requirement, in account assignment tab we need to use a custom
    cost centre field (ZCOST_CENTRE) instead of standard cost centre field.It is observed that for standard cost centre field there is a standard web-dynpro search-help assigned where it will return the F4 search help values from backend.
    Can any one of you please help me how can I assign the search-help for the custom cost centre field. Is there any FM to call the backend cost centre search help for custom field or any other way how can I achieve this?
    Thanks in advance.
    Regards,
    Kalyani

    kalyani,
    i can see your requirement in below way..
    as it just reads: you need to assign the standard cost center help to a z cost center field in component /SAPSRM/WDC_UI_DO_ACC.. which actually is fetched though the component /SAPSRM/WDC_UI_BACKEND_SH
    so, if you see the component controller of SAPSRM/WDC_UI_DO_ACC you will see the component
    USAGE_SH_F4     /SAPSRM/WDC_UI_BACKEND_SH                        
    USAGE_SH_F4     /SAPSRM/WDC_UI_BACKEND_SH     INTERFACECONTROLLER
    so you can replicate the same functionality for your z field.
    but can you clarify one thing.. why are you going for this z field in place of standard field ?

  • Reg : F4 help for custom fields in ALV report

    hi friends..
    in my internal table i have fields including 1 custom field..
    DATA : BEGIN OF i_final OCCURS 0,
      pernr LIKE p0000-pernr,
      begda LIKE p0000-begda,
      plans LIKE ZPOSITION-plans,  (custom)
      werks LIKE pspar-werks,
      end of i_final.
    i want to display this i_final table in alv. for that i genetrate one fieldcatalog
    PERFORM fcat USING:
                      'I_FINAL' 'PERNR' 'P0000' 'PERNR' '15' 'X' '',
                      'I_FINAL' 'BEGDA' 'P0000' 'BEGDA' '10' 'X' '',
                      'I_FINAL' 'PLANS' 'ZPOSITION' 'PLANS' '8' 'X' '',
                      'I_FINAL' 'WERKS' 'PSPAR' 'WERKS' '14' 'X' ''.
    in custom table zposition, i maintain serch help for custom field "PLANS".
    then i used reuse_alv_grid_display.. for all the std fields along wit custom fields
    i got f4 all std fields but for my custom i am not getting the f4 help
    how can i get the F$ help for this custom fields Zposition-plans..
    plz give some idea

    Hi
    In that Ztable against the field
    PLANS give the check table name as  <b>T528B</b>
    then it will automatically give the search help
    or you can create your own search help(elementary) and add to that field
    Reward if useful
    regards
    Anji

  • Search help for a field in table control based on another field value

    Hi,
    I want to attach the Search help for a field in table control based on another field value.
    Please help me asap.
    Will be highly rewarded

    HI,..
      Check these links
    search help in table control
    Re: How to create Search Help for a field in Table control !!
    How to create Search Help for a field in Table control !!
    F4 Help In Table Control
    Control table F4 help
    Problem in F4 help in screen field
    check this code
    DATA: BEGIN OF it_value4 OCCURS 0,
             TEXTCODE  LIKE  ZXX-TEXTCODE,
             TEXTDESC  LIKE  ZXX-TEXTDESC,
           END OF it_value4.
      progname = sy-repid.
      dynnum   = sy-dynnr.
             SELECT TEXTCODE TEXTDESC
               FROM  xxxx
               INTO CORRESPONDING FIELDS OF TABLE<b> it_value4</b>
              WHERE  LOSS_CODE =<b> IT_VALUE1 .</b>
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield    = 'TEXTCODE'
          dynpprog    = progname
          dynpnr      = dynnum
          dynprofield = 'ITVALUE-TEXTCODE'  "-->UR  4 th filed value in screen
          value_org   = 'S'
        TABLES
          value_tab   = it_value4.
    endmodule.
    Message was edited by:
            veereshbabu ponnada

  • How to change search help for standard field in me51n.

    hi frnds,
              I want to change search help option for 'Advice code' field under Additional DFPS tab in me51n. But i dont know how to change or add search help for standard field. so plz help..
    best regards,
    sudip biswas

    Hi Abhi,
    Try using any one option:
    Create a Search Help in SE11.
    Now Goto SE11 -> Enter Ztable -> Select that field -> Click Search Help and try to assign the created Search help to that field in your Ztable explicitly
    OR
    Create a Zdata element in SE11.
    In Data Element, under Further Characteristics tab, enter Name  Parameters of Search Help.
    Assign this data element to that field in ur Ztable.
    OR
    Create a Zdomain and maintain a Value Table or Fixed Values for it.
    Assign this domain to that field in ur Ztable.

  • Search Help for a Field of a Table Control

    I have designed a screen using 'Table Control' with fields like Date, BoxNo,Quantity etc. Kindly tell me how to go about providing a search help for the field 'BoxNo' of this table control so that the user is not required to scroll down the entire table/list for selecting a particular box no.
    Thanx in advance,
    Alok.

    When you go to screen painer, in screen painter attributes window, there is an atribute called search help, fill it.
    Another way is, after PAI put:
    PROCESS ON VALUE-REQUEST.
      FIELD box_no MODULE f1_help_box_no.
    And gives logic in that module using FM F4IF_INT_TABLE_VALUE_REQUEST.
    Regards.

  • How to add a search help for a field in Screen Personas?

       I just started learning to use a Screen Personas, and I want to know how to add a search help for a field.
       I found a property in the help document named "IsLookupSupported". Is it the key?  But I saw it was gray in the field I created, and its value is "false". I could not change it.

    Hi, Tamas,
    I found the reason. The function Z_WEBRFC_READ_DATA_SH had a string concatenation error.
    CONCATENATE '{"results":[{"key": "shlpname", "value": "' l_shlp '"},"key": "fieldname", "value": "' l_field '"}]}' INTO htmldoc-line.
    The correct code is like:
    CONCATENATE '{"results":[{"key": "shlpname", "value": "' l_shlp '"},{"key": "fieldname", "value": "' l_field '"}]}' INTO htmldoc-line.
    Another question is, I can't get any words in Chinese from WebRFC. It returns error when I try it. How can I configure it?
    Xin

  • How to create Search Help for a field in Table control !!

    Hello Friends,
                  I like to know - How to create Search Help for a field in Table control. Is it possible, if it is please share ur knowledge, I wud be happy if U provide some source code example for this.
    Thanks,
    Senthil

    Check the sample code:
    *&  Include           ZSRO_MPRN_SEARCH                                 *
    MODULE PSTLZ_F4 INPUT
    MODULE pstlz_f4 INPUT.
    reading post code
      DATA: stepl TYPE systepl,
            stepl_index TYPE systepl.
      CLEAR: stepl, stepl_index.
      CLEAR:   lt_returntab,lt_dynpfields,i_mprn1.
      REFRESH: lt_returntab,lt_dynpfields,i_mprn1.
      lt_dynpfields-fieldname = 'I_MPRN-POST_CODE'.
      lt_dynpfields-stepl     = stepl.
      APPEND lt_dynpfields. CLEAR lt_dynpfields.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = c_x
          determine_loop_index = c_x
        TABLES
          dynpfields           = lt_dynpfields
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dynpfields INDEX 1.
      ENDIF.
      ws_outcode  = lt_dynpfields-fieldvalue.
      stepl_index = lt_dynpfields-stepl.
      REPLACE '*' WITH ' ' INTO lt_dynpfields-fieldvalue.
      IF NOT lt_dynpfields-fieldvalue IS INITIAL.
        MOVE lt_dynpfields-fieldvalue TO ws_outcode.
        ws_len = STRLEN( lt_dynpfields-fieldvalue ).
        IF ws_len GE 7.
          ws_len = ws_len - 3.
         ws_icode = ws_code+ws_len(3).
          lt_dynpfields-fieldvalue = lt_dynpfields-fieldvalue+0(ws_len).
          CONCATENATE lt_dynpfields-fieldvalue '%'
              INTO ws_outcode.
          CONDENSE lt_dynpfields-fieldvalue.
       REPLACE ws_icode WITH ' ' INTO lt_dynpfields-fieldvalue.
        ELSE.
          CONCATENATE lt_dynpfields-fieldvalue+0(4) '%'
            INTO ws_outcode.
        ENDIF.
       ws_ocode = ws_code+0(3).
      ENDIF.
    reading MPRN
      CLEAR:   lt_returntab,lt_dnpfields,i_mprn1.
      REFRESH: lt_returntab,lt_dnpfields,i_mprn1.
      lt_dnpfields-fieldname = 'I_MPRN-MPRN'.
      lt_dnpfields-stepl     = stepl_index.
      APPEND lt_dnpfields. CLEAR lt_dnpfields.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = 'X'
        TABLES
          dynpfields           = lt_dnpfields
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dnpfields INDEX 1.
      ENDIF.
    MPRN blank and Post code exist
      IF lt_dnpfields-fieldvalue IS INITIAL.
        IF NOT lt_dynpfields-fieldvalue IS INITIAL.
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE outcode LIKE ws_outcode.
        ELSE.
    MPRN blank and Post code blank
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1.
        ENDIF.
      ELSE.
    MPRN exist and Post code exist
        IF NOT lt_dynpfields-fieldvalue IS INITIAL.
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE outcode LIKE ws_outcode AND
                       mprn EQ lt_dnpfields-fieldvalue.
        ELSE.
    MPRN exist and Post code blank
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE mprn EQ lt_dnpfields-fieldvalue.
        ENDIF.
      ENDIF.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'MPRN'
          dynpprog        = sy-repid
          dynpnr          = sy-dynnr
          window_title    = 'Select MPRN'
          value_org       = 'S'
        TABLES
          value_tab       = i_mprn1 "lt_mprn
          return_tab      = lt_returntab
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
      IF sy-subrc EQ 0.
        READ TABLE lt_returntab INDEX 1.
        READ TABLE i_mprn1 WITH KEY mprn = lt_returntab-fieldval.
        IF sy-subrc EQ 0.
    Updating post code
          CONCATENATE i_mprn1-outcode  i_mprn1-incode
                        INTO ws_postcode
                             SEPARATED BY space.
          MOVE ws_postcode TO i_mprn-post_code.
          CLEAR   : i_dnpfld,
                    ws_dynpfld.
          REFRESH : i_dnpfld.
          ws_dyname   = 'ZSRO_MASTER_DATA'.
          ws_dynumb   = '0301'.
          ws_dynpfld-fieldname  ='I_MPRN-POST_CODE'.
          ws_dynpfld-fieldvalue = ws_postcode .
          ws_dynpfld-stepl      = stepl_index.
          APPEND ws_dynpfld TO i_dnpfld.
          CALL FUNCTION 'DYNP_VALUES_UPDATE'
            EXPORTING
              dyname               = ws_dyname
              dynumb               = ws_dynumb
            TABLES
              dynpfields           = i_dnpfld
            EXCEPTIONS
              invalid_abapworkarea = 1
              invalid_dynprofield  = 2
              invalid_dynproname   = 3
              invalid_dynpronummer = 4
              invalid_request      = 5
              no_fielddescription  = 6
              undefind_error       = 7
              OTHERS               = 8.
          IF sy-subrc <> 0.
          ENDIF.
    Updating MPRN
          MOVE i_mprn1-mprn TO i_mprn-mprn.
          CLEAR   : i_dnpfld,
                    ws_dynpfld.
          REFRESH : i_dnpfld.
          ws_dyname   = 'ZSRO_MASTER_DATA'.
          ws_dynumb   = '0301'.
          ws_dynpfld-fieldname  ='I_MPRN-MPRN'.
          ws_dynpfld-fieldvalue = i_mprn1-mprn .
          ws_dynpfld-stepl      = stepl_index.
          APPEND ws_dynpfld TO i_dnpfld.
          CALL FUNCTION 'DYNP_VALUES_UPDATE'
            EXPORTING
              dyname               = ws_dyname
              dynumb               = ws_dynumb
            TABLES
              dynpfields           = i_dnpfld
            EXCEPTIONS
              invalid_abapworkarea = 1
              invalid_dynprofield  = 2
              invalid_dynproname   = 3
              invalid_dynpronummer = 4
              invalid_request      = 5
              no_fielddescription  = 6
              undefind_error       = 7
              OTHERS               = 8.
          IF sy-subrc <> 0.
          ENDIF.
        ENDIF.
      ELSEIF sy-subrc EQ 2.
        MESSAGE s005(zspa) WITH ws_postcode .
      ENDIF.
    ENDMODULE.                    "PSTLZ_F4 INPUT
    MODULE MPRN_F4 INPUT
    MODULE mprn_f4 INPUT.
    reading post code
    DATA: stepl TYPE systepl,
           stepl_index TYPE systepl.
      CLEAR: stepl, stepl_index.
      CLEAR:   lt_returntab,lt_dynpfields,i_mprn1.
      REFRESH: lt_returntab,lt_dynpfields,i_mprn1.
      lt_dynpfields-fieldname = 'I_MPRN-POST_CODE'.
      lt_dynpfields-stepl     = stepl.
      APPEND lt_dynpfields. CLEAR lt_dynpfields.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = c_x
          determine_loop_index = c_x
        TABLES
          dynpfields           = lt_dynpfields
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dynpfields INDEX 1.
      ENDIF.
      ws_outcode = lt_dynpfields-fieldvalue.
      stepl_index = lt_dynpfields-stepl.
      REPLACE '*' WITH ' ' INTO lt_dynpfields-fieldvalue.
      IF NOT lt_dynpfields-fieldvalue IS INITIAL.
        MOVE lt_dynpfields-fieldvalue TO ws_outcode.
        ws_len = STRLEN( lt_dynpfields-fieldvalue ).
        IF ws_len GE 7.
          ws_len = ws_len - 3.
         ws_icode = ws_code+ws_len(3).
          lt_dynpfields-fieldvalue = lt_dynpfields-fieldvalue+0(ws_len).
          CONCATENATE lt_dynpfields-fieldvalue '%'
              INTO ws_outcode.
          CONDENSE lt_dynpfields-fieldvalue.
       REPLACE ws_icode WITH ' ' INTO lt_dynpfields-fieldvalue.
        ELSE.
          CONCATENATE lt_dynpfields-fieldvalue+0(4) '%'
            INTO ws_outcode.
        ENDIF.
       ws_ocode = ws_code+0(3).
      ENDIF.
    reading MPRN
      CLEAR:   lt_returntab,lt_dnpfields,i_mprn1.
      REFRESH: lt_returntab,lt_dnpfields,i_mprn1.
      lt_dnpfields-fieldname = 'I_MPRN-MPRN'.
      lt_dnpfields-stepl     = stepl_index.
      APPEND lt_dnpfields. CLEAR lt_dnpfields.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = 'X'
        TABLES
          dynpfields           = lt_dnpfields
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dnpfields INDEX 1.
      ENDIF.
    MPRN blank and Post code exist
      IF lt_dnpfields-fieldvalue IS INITIAL.
        IF NOT lt_dynpfields-fieldvalue IS INITIAL.
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE outcode LIKE ws_outcode.
        ELSE.
    MPRN blank and Post code blank
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1.
        ENDIF.
      ELSE.
    MPRN exist and Post code exist
        IF NOT lt_dynpfields-fieldvalue IS INITIAL.
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE outcode LIKE ws_outcode AND
                       mprn EQ lt_dnpfields-fieldvalue.
        ELSE.
    MPRN exist and Post code blank
          SELECT mprn ser_num sub_bud bud_name del_pt_alias
                 bud_num dep_street prin_street dbl_dep_street
                 dep_locty post_town county outcode incode
                 lg_site_ind file_date FROM zspa_mprn INTO
                 CORRESPONDING FIELDS OF TABLE i_mprn1
                 WHERE mprn EQ lt_dnpfields-fieldvalue.
        ENDIF.
      ENDIF.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'MPRN'
          dynpprog        = sy-repid
          dynpnr          = sy-dynnr
          window_title    = 'Select MPRN'
          value_org       = 'S'
        TABLES
          value_tab       = i_mprn1 "lt_mprn
          return_tab      = lt_returntab
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
      IF sy-subrc EQ 0.
        READ TABLE lt_returntab INDEX 1.
        READ TABLE i_mprn1 WITH KEY mprn = lt_returntab-fieldval.
        IF sy-subrc EQ 0.
    Updating MPRN
          MOVE i_mprn1-mprn TO i_mprn-mprn.
          CLEAR   : i_dnpfld,
                    ws_dynpfld.
          REFRESH : i_dnpfld.
          ws_dyname   = 'ZSRO_MASTER_DATA'.
          ws_dynumb   = '0301'.
          ws_dynpfld-fieldname  ='I_MPRN-MPRN'.
          ws_dynpfld-fieldvalue = i_mprn1-mprn .
          ws_dynpfld-stepl      = stepl_index.
          APPEND ws_dynpfld TO i_dnpfld.
    **code changed by laxman 10.08.2005
         ws_dynpfld-stepl  = mprn-current_line.
    **code changed by laxman 10.08.2005
          CALL FUNCTION 'DYNP_VALUES_UPDATE'
            EXPORTING
              dyname               = ws_dyname
              dynumb               = ws_dynumb
            TABLES
              dynpfields           = i_dnpfld
            EXCEPTIONS
              invalid_abapworkarea = 1
              invalid_dynprofield  = 2
              invalid_dynproname   = 3
              invalid_dynpronummer = 4
              invalid_request      = 5
              no_fielddescription  = 6
              undefind_error       = 7
              OTHERS               = 8.
          IF sy-subrc <> 0.
          ENDIF.
    Updating post code
          CONCATENATE i_mprn1-outcode  i_mprn1-incode
                        INTO ws_postcode
                             SEPARATED BY space.
          MOVE ws_postcode TO i_mprn-post_code.
          CLEAR   : i_dnpfld,
                    ws_dynpfld.
          REFRESH : i_dnpfld.
          ws_dyname   = 'ZSRO_MASTER_DATA'.
          ws_dynumb   = '0301'.
          ws_dynpfld-fieldname  ='I_MPRN-POST_CODE'.
          ws_dynpfld-fieldvalue = ws_postcode .
          ws_dynpfld-stepl      = stepl_index.
          APPEND ws_dynpfld TO i_dnpfld.
    **code changed by laxman 10.08.2005
         break gblap0.
         ws_dynpfld-stepl  = mprn-current_line.
         LOOP AT i_mprn.
           MOVE i_mprn1-mprn TO i_mprn-mprn.
           MOVE ws_postcode TO i_mprn-post_code.
           MODIFY i_mprn INDEX
                    mprn-current_line." transporting MPRN POST_CODE.
         ENDLOOP.
    **code changed by laxman 10.08.2005
          CALL FUNCTION 'DYNP_VALUES_UPDATE'
            EXPORTING
              dyname               = ws_dyname
              dynumb               = ws_dynumb
            TABLES
              dynpfields           = i_dnpfld
            EXCEPTIONS
              invalid_abapworkarea = 1
              invalid_dynprofield  = 2
              invalid_dynproname   = 3
              invalid_dynpronummer = 4
              invalid_request      = 5
              no_fielddescription  = 6
              undefind_error       = 7
              OTHERS               = 8.
          IF sy-subrc <> 0.
          ENDIF.
        ENDIF.
      ELSEIF sy-subrc EQ 2.
        MESSAGE s006(zspa) WITH i_mprn1-mprn .
      ENDIF.
    ENDMODULE.                    "MPRN_F4 INPUT
    MODULE GNTC_F4 INPUT
    MODULE gntc_f4 INPUT.
      DATA: BEGIN OF lt_gntc OCCURS 0,
              gntc LIKE iflot-zzgntc,
            END OF lt_gntc.
      CLEAR:   lt_returntab, lt_gntc.
      REFRESH: lt_returntab, lt_gntc.
      lt_gntc-gntc = 'DM'.
      APPEND lt_gntc. CLEAR lt_gntc.
      lt_gntc-gntc = 'NDM'.
      APPEND lt_gntc. CLEAR lt_gntc.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'ZZGNTC'
          dynpprog        = sy-repid
          dynpnr          = sy-dynnr
          window_title    = 'Select Gas Nomination Type Code'
          value_org       = 'S'
        TABLES
          value_tab       = lt_gntc
          return_tab      = lt_returntab
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
      IF sy-subrc EQ 0.
        READ TABLE lt_returntab INDEX 1.
        i_mprn-dm_ndm = lt_returntab-fieldval.
      ENDIF.
    ENDMODULE.                    "GNTC_F4 INPUT
    *&      Module  mprn1_f4  INPUT
          text
    MODULE mprn1_f4 INPUT.
      DATA: lt_f4          TYPE ddshretval OCCURS 0 WITH HEADER LINE,
            lt_returntab1  LIKE ddshretval OCCURS 0 WITH HEADER LINE,
            lt_dynpfields1 LIKE dynpread OCCURS 0 WITH HEADER LINE,
            lt_dnpfields1  LIKE dynpread OCCURS 0 WITH HEADER LINE.
      DATA: stepl1 TYPE systepl,
            stepl_index1 TYPE systepl.
      DATA : i_dnpfld1      LIKE dynpread OCCURS 0 WITH HEADER LINE,
             ws_dyname1     LIKE d020s-prog,
             ws_dynumb1     LIKE d020s-dnum,
             ws_dynpfld1    LIKE dynpread.
      CLEAR: i_dnpfld1,  ws_dyname1, ws_dynumb1, ws_dynpfld1,
             lt_f4, lt_returntab1,lt_dynpfields1, lt_f4,
             stepl1, stepl_index1.
      REFRESH: i_dnpfld1, lt_returntab1,lt_dynpfields1, lt_f4.
    To Determine Steploop Index
      lt_dynpfields1-fieldname = 'I_MPRN-POST_CODE'.
      lt_dynpfields1-stepl     = stepl1.
      APPEND lt_dynpfields1. CLEAR lt_dynpfields1.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = 'X'
          determine_loop_index = 'X'
        TABLES
          dynpfields           = lt_dynpfields1
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dynpfields1 INDEX 1.
      ENDIF.
      stepl_index1 = lt_dynpfields1-stepl.
      CALL FUNCTION 'F4IF_FIELD_VALUE_REQUEST'
        EXPORTING
          tabname           = 'IFLOT'
          fieldname         = 'I_MPRN-MPRN'
          searchhelp        = 'ZS_MPRN_PC'
          dynpprog          = sy-repid
          dynpnr            = sy-dynnr
        TABLES
          return_tab        = lt_f4
        EXCEPTIONS
          field_not_found   = 1
          no_help_for_field = 2
          inconsistent_help = 3
          no_values_found   = 4
          OTHERS            = 5.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
        WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    Update tablecontrol
      READ TABLE lt_f4 WITH KEY fieldname = 'MPRN'.
      IF sy-subrc = 0.
        MOVE lt_f4-fieldval TO i_mprn-mprn.
        ws_dyname1   = 'ZSRO_MASTER_DATA'.
        ws_dynumb1   = '0301'.
        ws_dynpfld1-fieldname  ='I_MPRN-MPRN'.
        ws_dynpfld1-fieldvalue = i_mprn-mprn.
        ws_dynpfld1-stepl      = stepl_index1.
        APPEND ws_dynpfld1 TO i_dnpfld1.
        CALL FUNCTION 'DYNP_VALUES_UPDATE'
          EXPORTING
            dyname               = ws_dyname1
            dynumb               = ws_dynumb1
          TABLES
            dynpfields           = i_dnpfld1
          EXCEPTIONS
            invalid_abapworkarea = 1
            invalid_dynprofield  = 2
            invalid_dynproname   = 3
            invalid_dynpronummer = 4
            invalid_request      = 5
            no_fielddescription  = 6
            undefind_error       = 7
            OTHERS               = 8.
        IF sy-subrc <> 0.
        ENDIF.
      ENDIF.
      CLEAR  : i_dnpfld1, ws_dynpfld1.
      REFRESH: i_dnpfld1.
      READ TABLE lt_f4 WITH KEY fieldname = 'ZZPSTLZ'.
      IF sy-subrc = 0.
        MOVE lt_f4-fieldval TO i_mprn-post_code.
        ws_dyname1   = 'ZSRO_MASTER_DATA'.
        ws_dynumb1   = '0301'.
        ws_dynpfld1-fieldname  ='I_MPRN-POST_CODE'.
        ws_dynpfld1-fieldvalue = i_mprn-post_code.
        ws_dynpfld1-stepl      = stepl_index1.
        APPEND ws_dynpfld1 TO i_dnpfld1.
        CALL FUNCTION 'DYNP_VALUES_UPDATE'
          EXPORTING
            dyname               = ws_dyname1
            dynumb               = ws_dynumb1
          TABLES
            dynpfields           = i_dnpfld1
          EXCEPTIONS
            invalid_abapworkarea = 1
            invalid_dynprofield  = 2
            invalid_dynproname   = 3
            invalid_dynpronummer = 4
            invalid_request      = 5
            no_fielddescription  = 6
            undefind_error       = 7
            OTHERS               = 8.
        IF sy-subrc <> 0.
        ENDIF.
      ENDIF.
    ENDMODULE.                 " mprn1_f4  INPUT
    *&      Module  pstlz1_f4  INPUT
          text
    MODULE pstlz1_f4 INPUT.
      CLEAR: i_dnpfld1,  ws_dyname1, ws_dynumb1, ws_dynpfld1,
              lt_f4, lt_returntab1,lt_dynpfields1, lt_f4,
              stepl1, stepl_index1.
      REFRESH: i_dnpfld1, lt_returntab1,lt_dynpfields1, lt_f4.
    To Determine Steploop Index
      lt_dynpfields1-fieldname = 'I_MPRN-MPRN'.
      lt_dynpfields1-stepl     = stepl1.
      APPEND lt_dynpfields1. CLEAR lt_dynpfields1.
      CALL FUNCTION 'DYNP_VALUES_READ'
        EXPORTING
          dyname               = sy-repid
          dynumb               = sy-dynnr
          translate_to_upper   = 'X'
          determine_loop_index = 'X'
        TABLES
          dynpfields           = lt_dynpfields1
        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.
      IF sy-subrc EQ 0.
        READ TABLE lt_dynpfields1 INDEX 1.
      ENDIF.
      stepl_index1 = lt_dynpfields1-stepl.
      CALL FUNCTION 'F4IF_FIELD_VALUE_REQUEST'
        EXPORTING
          tabname           = 'IFLOT'
          fieldname         = 'I_MPRN-POST_CODE'
          searchhelp        = 'ZS_MPRN_PC'
          dynpprog          = sy-repid
          dynpnr            = sy-dynnr
        TABLES
          return_tab        = lt_f4
        EXCEPTIONS
          field_not_found   = 1
          no_help_for_field = 2
          inconsistent_help = 3
          no_values_found   = 4
          OTHERS            = 5.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
        WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    Update tablecontrol
      READ TABLE lt_f4 WITH KEY fieldname = 'ZZPSTLZ'.
      IF sy-subrc = 0.
        MOVE lt_f4-fieldval TO i_mprn-post_code.
        ws_dyname1   = 'ZSRO_MASTER_DATA'.
        ws_dynumb1   = '0301'.
        ws_dynpfld1-fieldname  ='I_MPRN-POST_CODE'.
        ws_dynpfld1-fieldvalue = i_mprn-post_code.
        ws_dynpfld1-stepl      = stepl_index1.
        APPEND ws_dynpfld1 TO i_dnpfld1.
        CALL FUNCTION 'DYNP_VALUES_UPDATE'
          EXPORTING
            dyname               = ws_dyname1
            dynumb               = ws_dynumb1
          TABLES
            dynpfields           = i_dnpfld1
          EXCEPTIONS
            invalid_abapworkarea = 1
            invalid_dynprofield  = 2
            invalid_dynproname   = 3
            invalid_dynpronummer = 4
            invalid_request      = 5
            no_fielddescription  = 6
            undefind_error       = 7
            OTHERS               = 8.
        IF sy-subrc <> 0.
        ENDIF.
      ENDIF.
      CLEAR  : i_dnpfld1, ws_dynpfld1.
      REFRESH: i_dnpfld1.
      READ TABLE lt_f4 WITH KEY fieldname = 'MPRN'.
      IF sy-subrc = 0.
        MOVE lt_f4-fieldval TO i_mprn-mprn.
        ws_dyname1   = 'ZSRO_MASTER_DATA'.
        ws_dynumb1   = '0301'.
        ws_dynpfld1-fieldname  ='I_MPRN-MPRN'.
        ws_dynpfld1-fieldvalue = i_mprn-mprn.
        ws_dynpfld1-stepl      = stepl_index1.
        APPEND ws_dynpfld1 TO i_dnpfld1.
        CALL FUNCTION 'DYNP_VALUES_UPDATE'
          EXPORTING
            dyname               = ws_dyname1
            dynumb               = ws_dynumb1
          TABLES
            dynpfields           = i_dnpfld1
          EXCEPTIONS
            invalid_abapworkarea = 1
            invalid_dynprofield  = 2
            invalid_dynproname   = 3
            invalid_dynpronummer = 4
            invalid_request      = 5
            no_fielddescription  = 6
            undefind_error       = 7
            OTHERS               = 8.
        IF sy-subrc <> 0.
        ENDIF.
      ENDIF.
    ENDMODULE.                 " pstlz1_f4  INPUT
    Regards,
    Prakash.

  • Search help for A field in select option which doesnt have search help in c

    u have table in QM which is QMFE in whihc field FECOD which doesnt have search help , but my requirement is that in select option in report to have users to see its search help, anyone there to help me

    Hi sridhar loganathan,
    For this goto SE11 and create a ZFECOD Search help for that field. In Defination Tab enter table name
    QMFE and Enter Z_F4_FECOD_EXIT in Search help Exit.
    Then create a FM in SE37 as Z_F4_FECOD_EXIT under a FG. And then write code as follows for example: 
    FUNCTION Z_F4_REG_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
      TYPES: begin of ty_code,
              dam_code type  QMFE-FECOD ,
            end of ty_code.
      DATA : tw_code type ty_code,
             ta_code type table of ty_code.
       IF  "callcontrol-step <> 'SELONE' AND
            callcontrol-step <> 'SELECT' AND
            callcontrol-step <> 'DISP'.
          EXIT.
        ENDIF.
       IF callcontrol-step = 'SELECT'.
          CALL FUNCTION 'F4UT_PARAMETER_ALLOCATE'
            EXPORTING
                 PARAMETER         = 'FECOD'
            TABLES
                 SHLP_TAB          = shlp_tab
                 RECORD_TAB        = record_tab
            CHANGING
                 SHLP              = shlp
                 CALLCONTROL       = callcontrol
            EXCEPTIONS
                 OTHERS            = 3.
       ENDIF.
       IF callcontrol-step = 'DISP'.
    Get the Region
          CALL FUNCTION 'F4UT_PARAMETER_VALUE_GET'
             EXPORTING
                  PARAMETER         = 'FECOD'
                  FIELDNAME         = 'FECOD'
             TABLES
                  SHLP_TAB          = shlp_tab
                  RECORD_TAB        = record_tab
                  RESULTS_TAB       = ta_code
             CHANGING
                  SHLP              = shlp
                  CALLCONTROL       = callcontrol
             EXCEPTIONS
                  PARAMETER_UNKNOWN = 1
                  OTHERS            = 2.
           IF SY-SUBRC = 0.
              SORT TA_CODE BY DAM_CODE.
    Deleting duplicate damage codes in Internal Table ta_code
              DELETE ADJACENT DUPLICATES FROM TA_CODE COMPARING DAM_CODE.
    Passing changed Internal table to FM
              CALL FUNCTION 'F4UT_PARAMETER_RESULTS_PUT'
              EXPORTING
                 PARAMETER         = 'REGION'
                 FIELDNAME         = 'REGION'
              TABLES
                 SHLP_TAB          = shlp_tab
                 RECORD_TAB        = record_tab
                 SOURCE_TAB        = ta_code
              CHANGING
                 SHLP              = shlp
                 CALLCONTROL       = callcontrol
              EXCEPTIONS
                 PARAMETER_UNKNOWN = 1
                 OTHERS            = 2.
           ENDIF.
       ENDIF.
    ENDFUNCTION.
    Revert me for any clarifications.
    Regards,
    Suneel G.

Maybe you are looking for

  • How can I solve issues with moving mail to different folders?

    I am not able to move certain files from one folder to another? I get a pop up that says, "unable to move message" and right underneath that it says, "the message could not be moved to the mailbox inbox". It will not allow me to move anything in that

  • How do I change the name of my calendar on my iPhone 5

    How do I change the name of my calendar on my iPhone 5

  • ODI Number of Running Sessions

    Hello guys !! A cuestion, I'm doing a package with a parallel process, but this only raises 3 maximum sessions at the same time, when I hope it raises 9 how can I increase the Number of running sessions / Maximum number of sessions for the agent? Als

  • Pointer Tool Click Zones

    These are great and I use them all the time, but I do have a problem with the top and bottom arrangement. Just lately I have been spending a bit more time in Pro tools (hence the multi tool) and have suddenly realised upon jumping back into Logic lan

  • Diff between oracle 8i sql Engine and oracle 9i sql Engine

    hi, 1)Can anyone tell me difference between oracle8i sql engine and 9i sql engine. 2)Does oracle 9i uses the index defaultly if any primary key is there in table Thanks Rama