cancel
Showing results for 
Search instead for 
Did you mean: 

Read only/Grayout input field based on condition in FPM GUIBB

former_member231368
Participant
0 Kudos

Hi All,

Presently I working on Floorplan Manager for SAP EHSM module. I am new to this & having some technical challenges.

Requirements:

1. I have added a custom field to the FPM screen and the same needs to be gray out/read only mode based on some condition. I am able to see the filed on the screen updating the value into corresponding tables without writing any code since added this into BO structures.

Now challenge is I am unable to grayout the field. I wrote the code in FEEDER CLASS OF

GET_DEFINITION - Actions

GET_DATA - Making field in gray our or display. But it is not working as expected. Kindly do let me know whether the code is in right place or not.

field-symbols: <fs_FPMGB_S_FIELDUSAGE> type FPMGB_S_FIELDUSAGE,
<lv_field> TYPE any.

LOOP AT ct_field_usage assigning <fs_FPMGB_S_FIELDUSAGE> WHERE name EQ 'ZZEHSM_LEVELS'.

ASSIGN COMPONENT 'ZZEHSM_NEW_NR' OF STRUCTURE cs_data TO <ls_nr_id>.

ASSIGN COMPONENT 'ZZEHSM_LEVELS' OF STRUCTURE cs_data TO <lv_field>.SELECT

SINGLE *FROM ehhssd_inc_binfaINTO wa_ehhssd_inc_binfaWHERE zzehsm_new_nr = <ls_nr_id>.

IF NOT wa_ehhssd_inc_binfa-zzehsm_levels IS INITIAL.
<fs_FPMGB_S_FIELDUSAGE>-read_only = abap_true.
ev_field_usage_changed = abap_true.
ENDIF.

endloop.

Kindly help on this.

Thanks,

Setty

former_member231368
Participant
0 Kudos

I tried as per the below blog post too... but it didn't worked out..

https://archive.sap.com/discussions/thread/3338816

former_member231368
Participant
0 Kudos

Hi All,

Does anyone find the solution. Can you please pass the steps to achieve.

Thanks,

Yerukala Setty

Accepted Solutions (0)

Answers (0)