The PeopleSoft message catalog (or catalogue) is used to store errors, warnings and information messages in a common repository. It is really a fantastic example of reuse - all messages are stored in the one location.
You can access the message catalog using the following navigation:
Behind the scenes, the message catalog uses the following PeopleTools records:
PSMSGSETDEFN- Messages group by message set (a header record really)
PSMSGSETLANG- Related language record for
PSMSGCATDEFN- Messages grouped by message set and number
PSMSGCATLANG- Related language record for
One way to allocate message sets is by a base unit of work (an Application Designer project for instance). However, you may find that you don't end up creating a lot of messages, so the other option is to use just one message set. Perhaps you might divide your message sets up by functional area. There are numerous options, but the key is to use a standard approach.
There are three things you need to decide when you create a message:
- The severity (cancel, error, message, warning)
- The message text
- The explanation
Severity is important. For example, the
MessageBox function treats message severity as follows (from PeopleBooks):
Message: The message is displayed and processing continues
Warning: The message is displayed and treated as a warning
Error: The message is displayed and treated as an error
Cancel: The message is displayed and forces a Cancel
Based on the above scenarios you should be able to pick what type of message you are dealing with. Remember that an error stops processing while a warning does not.
I like to use message text as stating the error, warning or information as succinctly as possible.
The message text is limited to a maximum of
100 characters. You can pass bind values (
%1, %2, %3 ... %n) to the message text using PeopleCode functions like
MsgGetExplainText is to pass bind values to the explain text and not the message text.
The explain text is a good place to tell the user further information or what to do to fix an error or why a warning is being given. Don't just repeat the message text.
You can pass bind values (
%1, %2, %3 ... %n) to the explain text but only using the
MsgGetExplainText PeopleCode function.