If you would like to report on the message text without actually "throwing" it, use:
MESSAGE I123(XX) WITH 'Parameter 1' Param2 INTO full_message_text
This will make the message available as a variabele you can report on.
So messages always relate to a message number ? No they don't. You may have come across the 000 or 999 messages under many message ID's that have a placeholder function only. The text for these messages is
& & & & and the developer can fill in any parameters he/she likes.
If you've assembled/gathered a list of messages, there are several ways to take messaging further. There is a class
CL_ERROR_MSG available which can be used to add messages to (method
SET, messages can be counted (method
GET_COUNT - use to determine whether display is needed) and a popup with the messages can be displayed (method
DISPLAY) with a suite of functions. You may also want to consider using the Business Application Log (BAL)