In selection-screen, generated dynpro, the function code associated to the icon is not defined as an Exit function key. (Even if you change the generated screen, it will be regenerated soon or later...) so the obligatory/required flag will be checked before execution of user-command.
So you could remove the obligatory option in parameters/select-options fields.Then execute the check in a AT SELECTION-SCREEN [ON field], - hint: you could also check that SSCRFIELDS-UCOMM is 'ONLI' or 'PRIN' or doesn't start with '%' (%001, %002, etc.)
Regards,
Raymond
For the issue that you marked as red is an standard one .
You must have used NO INTERVALS after select options like --
select-options : s_matnr type mara-matnr no intervals.
For the second issue , This is again an standard one as the obligatory condition will be checked everytime you do something on screen. (clicking arrow , executing etc).
Workaround for this is --
Let's say you want to display a message error "fill in all required fields."
In at-selection-screen event , write this -
IFsy-ucomm EQ 'ONLI'.
IF s_matnr-low IS INITIAL OR p_class IS INITIAL.
MESSAGE 'fill all required fields' TYPE 'E'.
ENDIF.
ENDIF.
so your empty mandatory fields will only get checked when you try to execute your report.
Regards,
Saddam
Add a comment