Check Modules
When maintaining an external command, you can specify the name of a check module. A check module is a function module that is executed immediately before the command, and can decide whether the command will be executed or not.
Your system already contains the prototype of such a check module:
SXPG_DUMMY_COMMAND_CHECK
The check module contains an ABAP comment with an example of how it is used.
Do not change the check module SXPG_DUMMY_COMMAND_CHECK, but instead work with a copy. You can freely define the name of the check module. Only the interface has to be the same as for the check module SXPG_DUMMY_COMMAND_CHECK. The check module can only stop the execution of the command by triggering the exception NO_PERMISSION.
See also:
Processing Illegal Changes to External Commands
Syslog Trace and System Alert Monitor