Wondering why there are 3 different functions or ways to get text
from a message catalog? Check the comparison below and decide which one
best fits your needs.
MsgGet(message_set, message_num, default_msg_txt [, paramlist])
The MsgGet function
retrieves a message from the PeopleCode Message Catalog and substitutes
in the values of the parameters into the text message.
Example: &MsgText = MsgGet(30000, 2, "Message not found");
MessageBox
retrieves messages from the Message Catalog but provides the
flexibility to change the severity of a message through the Message
Catalog, without modifying PeopleCode.
MessageBox(style, title, message_set, message_num, default_txt [, paramlist])
Example: MessageBox(0, "", 30000, 1, "Message not found", BUS_EXPENSE_PER.EMPLID, BUS_EXPENSE_PER.EXPENSE_PERIOD_DT);
MsgGetText is very similar to MsgGet except the message set and message number will not appear after the text of the message.
MsgGetText(message_set, message_num, default_msg_txt [, paramlist])
Example: &MsgText = MsgGetText(30000, 2, "Message not found");
Title | Under | Posted on |
---|---|---|
Component interface Error: no rows exist for the specified keys | PeopleSoft Technical | 03/15/2019 - 3:54am |
ADD 24 months starting from current month.(peoplesoft) | PeopleSoft Functional | 07/29/2018 - 8:44pm |
TRC values dropdown | PeopleSoft Technical | 04/04/2018 - 12:54am |
how to find missing sequence in GRID and print the mising sequence number while saving through peoplecode | PeopleSoft Technical | 09/11/2017 - 4:49am |
Comments
If using the MessageBox command, how do you hide the message set and message number in a MessageBox? I understand how to do that using MsgGetText vs. MsgGet, but how do I hide the message set and message number using the MessageBox command?
I don't think that is possible.
Give back to the community and help it grow!
* Help with unanswered forum questions and issues
* Register or login to share your knowledge at your own blog
How do you hide the message set and message number in a MessageBox??
Here is the solution for hiding message set and message number,
WinMessage(MsgGetText(&MessageSet, &MessageNumber, "Alt Text"),0);
MessageBox(0, "", 0, 0, "Current Pay Run ID should be " | &RunID_S | " or " | &RunID_H);
WinMessage is a different command that doesn't provide for different buttons in the dialog box. So this is not a way to suppress the message catalog information in the dialog box.
There is no way to suppress the message catalog information in the dialog box.
MessageBox(0, "", 0, 0, "Current Pay Run ID should be " | &RunID_S | " or " | &RunID_H) will still display (0,0) in the dialog box.
There is no way to suppress the message catalog information in the dialog box.
Yes we can hide the Message Set and Message nUmber.
&ans = WinMessage(MsgGetText(0, 0, "Blah blah?", ¶m), 4);
Regards
Ankit Gupta