code pal for ABAP > Documentation > Message Translation
This check finds MESSAGE
statements where an untranslatable text literal is specified instead of a text element or message from a message class.
Use message classes or text elements instead.
In exceptional cases, you can suppress this finding by using the pseudo comment "#EC MSG_TRANSL
which has to be placed after the MESSAGE
statement.
Note that this check is a subset of a similar check in the Extended Program Check (SLIN) delivered by SAP. That check accepts a pragma ##NO_TEXT
for suppressing its findings that Code Pal cannot evaluate (pragmas are inaccessible to ordinary Code Inspector checks). We recommend that you either use this Code Pal check or the corresponding SLIN check, but not both, since if you use both you get two findings for the exact same issue.
MESSAGE 'File not found!' TYPE 'W'. "#EC MSG_TRANSL
Before the check:
MESSAGE 'File not found!' TYPE 'W'.
After the check:
MESSAGE i002(00).
or
MESSAGE TEXT-001 TYPE 'W'.