Buttons on Confirmation screen are not always active and visible. This page shows an entry point of code where conditions behind button visibility can be debugged.
The following chapter contains an entry point of code to debug different conditions of different buttons, and let the debugger find out why a button is enabled or disabled in it's current case.
Buttons on Confirmation screen
Various checks are performed at different points of code before a Confirmation is displayed. Each button is bounded to different conditions.
Instead of providing each condition related to buttons (which conditions could change by time by SAP Notes), there are breakpoints offered to self-check why a button is disabled or enabled.
There is a loop on table MT_IDR_ACTIONS in method UPDATE_ACTIONS that contains the possible buttons, which could be enabled or disabled. In this example:
|1 CONFIRM||8 SAVE||15 MEMORY_SNAPSHOT|
|2 RETURN||9 DELETE||16 FPM_CHECK_CLOSE|
|3 APPROVE||10 CANCEL||17 PRINT_PREVIEW|
|4 REJECT||11 REVERT||18 CHECK|
|5 SUBMIT_REVIEW||12 RETURNDELIVERY||19 EDIT|
|6 SHOW_MY_TASKS||13 EVALUATESUPPLIER||20 DISPLAY|
|7 CONFIRM_CANCELLATION||14 SYSTEM_STATUS||21 REFRESH|
Evaluation of conditions starts at method GET_ACTION_METADATA.
Field IV_ACTION contains the name of current button. You can switch between buttons by pressing F8 because of the loop at method UPDATEACTIONS. The code will run further until the next element in the list. Variable rv_enabled will contain X at the end of the method if button is enabled, and it will be initial if the button is disabled.
If more details are needed about reasons why button is enabled or disabled, then GET_ACTION_METADATA is the starting method wherefrom different code logics can be reached for different buttons.