Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

I can't default some thing on a field? Unbelievable!


By using GUIBB of FPM_SEARCH_UIBB I have created a SEARCH webdyn pro app and it has 5 fields in search criteria, SY-UNAME (current user name) is the 1st field in search criteria, its greyed out,well, now I want to DEFAULT currently logged in user ID on the 1st field, pls. let us know how we can achieve my requirement of defaulting some thing before view / screen is launched?

Former Member


To set default values to the search criteria using fpm_search_uibb.

Use the below code in your GET_DATA method of feeder class :

METHOD if_fpm_guibb_search~get_data.


            <fs_search_criteria> LIKE LINE OF ct_fpm_search_criteria.

   CASE io_event->mv_event_id.

     WHEN cl_fpm_event=>gc_event_start.


       " Set default values


       READ TABLE ct_fpm_search_criteria ASSIGNING <fs_search_criteria>

       WITH KEY search_attribute = 'ERNAM'. " field name

       IF sy-subrc IS INITIAL AND <fs_search_criteria> IS ASSIGNED.

         <fs_search_criteria>-low = sy-uname.


       " Inform the framework the search criteria is changed

       ev_search_criteria_changed = abap_true.

     WHEN if_fpm_guibb_search=>fpm_execute_search.

       et_result_list = mt_policy_hd.





0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question