on 01-03-2013 2:03 PM
Hi Team,
Could someone please throw light on how to make a read-only row in a column editable. I am using a List Guibb table(screenshot provided below) that consumes the interface IF_FPM_GUIBB_LIST within its own feeder class. The 3rd and 4th row in my second column(Business Partner) show up as read-only by the system. To make them editable i have used the 2 below approaches as mention in previous forum discussions but the rows just don't get editable :
Approach 1: IF_FPM_GUIBB_LIST~GET_DATA
LOOP AT ct_field_usage ASSIGNING <ls_field_usage> WHERE name = 'PARTY_ID'.
<ls_field_usage>-READ_ONLY = abap_false.
<ls_field_usage>-ENABLED = abap_true.
endloop.
ev_field_usage_changed = abap_true.
Approach 2: IF_FPM_GUIBB_LIST~GET_DEFINITION
FIELD-SYMBOLS <ls_field_descr> TYPE FPMGB_S_LISTFIELD_DESCR.
loop at et_field_description ASSIGNING <ls_field_descr> WHERE name = 'PARTY_ID'.
if sy-subrc eq 0.
<ls_field_descr>-read_only = abap_false.
<ls_field_descr>-read_only_ref = <ls_field_descr>-name.
ENDIF.
endloop.
Thanks in advance,
Vijay
Hi Vijay,
You are changing the values in the fields but you are not modifying the CT_Fieldusage as shown below in the code. DO that and it will work as you are expecting.
LOOP AT ct_field_usage INTO ls_field_usage.
ls_field_usage-read_only = abap_false.
ls_field_usage-enabled = abap_true.
MODIFY ct_field_usage FROM ls_field_usage TRANSPORTING read_only enabled.
CLEAR ls_field_usage.
ENDLOOP.
Thanks
Phani
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
thanks phani for the reply but using a work area makes no difference at all. however i have used your tip but it still is not editable.
I have used similar code for form_guibb input fields and it works but somehow the same approach does not work in case of a table that is part of a list_guibb.
could someone please throw light on this.
Thanks in advance,
Vijay
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.