cancel
Showing results for 
Search instead for 
Did you mean: 

F4 for custom field on UI not working correctly

Former Member
0 Kudos

Hello All

I have just started with CRM web UI .

as to do practise I have added a custom field into standard view for sales lead, now I want to add F4 help for this field.

I searched over SDN for help and found following wiki, I followed required steps .

Link: [http://wiki.sdn.sap.com/wiki/display/CRM/HowtoprovideF4Help]

By following above wiki F4 Icon is appearing on view and by clicking that I am getting values from DOMAIN also.

But problem is after selecting any value it is not coming to input field.

i.e. if I selected 100 form F4 help popup , this will not come into input field and field will be BLANK.

Please guide me.

Regards

Sachin

Accepted Solutions (1)

Accepted Solutions (1)

ajaya_kumar
Active Participant
0 Kudos

Hi Sachin,

Please share your code for creating the F4 help.

Regards

Ajay

Former Member
0 Kudos

Hello

Thanx for reply....I found error that I required to pass value of F4 filed in F4_ATTR insted of field name of view.

Regards

Sachin

AP85
Explorer
0 Kudos

Hi Sachin,

I am facing the same problem can you please tell me what you have passed in the F4_ATTR.

Regards,

Anshuman

Answers (2)

Answers (2)

former_member214667
Contributor
0 Kudos

Hi Sachin,

You need to pass the output mapping table when creating the input help. This mapping will determine which fields of the source (i.e. field from where F4 help was triggered) should the F4 help key (and value) be mapped to. Here is a sample code:


DATA:
ls_map TYPE if_bsp_wd_valuehelp_f4descr=>gtype_param_mapping,
lt_outmap TYPE if_bsp_wd_valuehelp_f4descr=>gtype_param_mapping_tab.

ls_map-context_attr = u2018STRUCT.BP_DESCRIPTIONu2019. " Field from where F4 help was triggered and selection needs to come back
ls_map-f4_attr = u2018UNITu2019. " Field in the search help
APPEND ls_map TO lt_outmap.

* Pass this output map to value help descriptor during creation

0 Kudos

Thank You Shiromani Sharma. I took your advice and I made the modifications and it works for me...





  data: ls_map    type if_bsp_wd_valuehelp_f4descr=>gtype_param_mapping,

          lt_inmap  type if_bsp_wd_valuehelp_f4descr=>gtype_param_mapping_tab,

         lt_outmap type if_bsp_wd_valuehelp_f4descr=>gtype_param_mapping_tab.

  ls_map-context_attr = 'EXT.ZZAFLD00008U'.  " This is the Field create via AET

  ls_map-f4_attr         = 'PERSON_ID' .             " This the Field from the Search Help "ZZAFLD00008U_SEARCH_HELP".

  append ls_map to: lt_inmap, lt_outmap.

  create object rv_valuehelp_descriptor type cl_bsp_wd_valuehelp_f4descr

    exporting

      iv_help_id   = 'ZZAFLD00008U_SEARCH_HELP' " This is Search help created via SE11.

      iv_help_id_kind   = if_bsp_wd_valuehelp_f4descr=>help_id_kind_name

      iv_input_mapping  = lt_inmap

      iv_output_mapping = lt_outmap.

former_member206299
Contributor
0 Kudos

Hi Sachin,

The thread seems to be fine for creating F4 Help.

Make sure that the context attribute to which ur mapping the F4 attribute is correct.

Regards,

Sijo