How to use MsgGet, MsgGetText and MsgGetExplainText by Peoplecode Function of Peoplesoft
MsgGet syntax
MsgGet(message_set, message_num, default_msg_txt[, paramlist])
Example: &MsgText = MsgGet(30000, 2, “Message not found”);
MsgGetText syntax
MsgGetText(message_set, message_num, default_msg_txt[, paramlist])
Example: &MsgText = MsgGetText(30000, 2, “Message not found”);
MsgGetExplainText(message_set, message_num, default_msg_txt[, paramlist])
Example1
If Message Catalog (100,1)= This is my name is %1 and i like pet is %2.
¶mlist1= “Joy”;
¶mlist2= “cat”;
MsgGetExplainText(100, 1, “Message not found”, paramlist1,¶mlist2)
Result= This is my name is Joy and i like pet is cat.
Example2
Define Message catalog :
message_set =20005
message_num= 4
Severity = Message
Message Text = Test Mail
Description = Email Tracking Coaching & Performance
Example of use each function
&MsgGet = MsgGet(20005, 4, “default_msg_txt”);
&MsgGet=Test Mail (20005,4)
&MsgGetText = MsgGetText(20005, 4, “default_msg_txt”);
&MsgGetText=Test Mail
&MsgGetExplainText = MsgGetExplainText(20005, 4, “default_msg_txt”);
&MsgGetExplainText=Email Tracking Coaching & Performance
WinMessage(“&MsgGet=” | &MsgGet);
WinMessage(“&MsgGetText=” | &MsgGetText);
WinMessage(“&MsgGetExplainText=” | &MsgGetExplainText);