‎2009 Sep 07 10:03 AM
Dear all,
I want to enable and disable the fields of field catalog at run time.
Example:
PRICE TYPE AMOUNT CURRENCY QUANTITY UNIT PERCENTAGE
P1 12.00 EUR 22 KG 1
If P1 changes to P2 I want to disable the fields AMOUNT & PERCENTAGE.
How I can achieve this please help.
I am calling the data_changed of class cl_gui_alv_grid but its not solving the purpose.
Kindly help
Thanks & Regards,
Divya Jain
‎2009 Sep 07 10:20 AM
‎2009 Sep 07 12:01 PM
In your event handler call following method with
call method CL_GUI_CFW=>SET_NEW_OK_CODE( ' ' ).
This will trigger your PAI with action ENTER. If you have any specific action on ENTER, define some dummy ok_code in your PF-STATUS and pass that dummy ok_code to above method. (You can call method to refresh ALV in your dummy ok_code).
Regards,
Mohaiyuddin
‎2009 Sep 08 12:33 PM
During the run-time you can evaluate the data. So when you have a change (according to your criteria) you can change the fieldcatalog (the field "EDIT" is controlloning if the field should be editable or not). Then you should reassign the fieldcatalog or by using the method SET_TABLE_FOR_FIRST_DISPLAY with the cobination of the set new ok_code method.
With regards
George.