2009 Jun 03 3:51 AM
Hi all,
I am using oops ALV and when i try to do a F4 on a editable field, it takes me to the event data_changed.
But I have not registed F4 event with the ALV. I dont want the F4 to trigger data_changed event. What do I need to do?
2009 Jun 03 4:31 AM
Hello
If you do not want to do do any pre-setting of values for the search help or post-processing (e.g. validation, update of ALV list depending on selected F4-value) then just ignore the fact that event DATA_CHANGED is raised, e.g.:
METHOD handle_data_changed.
CHECK ( e_onf4 = abap_false ). " = ' ' (space)
CHECK ( e_onf4_before = abap_false ).
CHECK ( e_onf4_after = abap_false ).
" ELSE: execute coding...
ENDMETHOD.
Regards
Uwe
Hi all,
I am using oops ALV and when i try to do a F4 on a editable field, it takes me to the event data_changed.
But I have not registed F4 event with the ALV. I dont want the F4 to trigger data_changed event. What do I need to do?
2009 Jun 03 4:31 AM
Hello
If you do not want to do do any pre-setting of values for the search help or post-processing (e.g. validation, update of ALV list depending on selected F4-value) then just ignore the fact that event DATA_CHANGED is raised, e.g.:
METHOD handle_data_changed.
CHECK ( e_onf4 = abap_false ). " = ' ' (space)
CHECK ( e_onf4_before = abap_false ).
CHECK ( e_onf4_after = abap_false ).
" ELSE: execute coding...
ENDMETHOD.
Regards
Uwe
2013 Nov 12 2:15 PM
That also works fine for me, but:
When the user presses 'SAVE' afterwards, I trigger the check_changed_data event. And now all other changes, expect the f4-help row, made by the user are gone.
So let's say the user changed 4 rows of the ALV. Afterwards, he presses the 'F4-Help' of one of the modified rows. Now your CHECK solution successfully stops the Modfication of the Database for all four entries.
However, when the user finished selecting his F4 value and presses 'SAVE' afterwards, then the database should be modified by all 4 rows. But because the data_changed event already raised as a result of the F4-help, only this row is now part of the er_data_changed->Mp_mod_rows.
So is there a solution to suppress the data_changed event after F4-Help completly?
Thanks,
Best regards
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |