You are viewing this site as a guest. You can still ask questions and help others! Join our Dev2Dev IT Community to receive your own blog, share your knowledge, and much more.

How to display more than two lines of error message

5 replies [Last post]
Guest's picture
Guest

Hi all,

my requirement is display an errormessage that contains more than 3 lines of message.when i try to create an error message in mesage catalouge (message text) it is accepting only one line of message.

i have given remaining message in Explain field in message catalogue and saved .
but iam getting error message like message text and below that explanation msg

i have concatinated these two message but still iam getting in same format.

can any one help me on this issue

Thanks,
preethi

Lepa's picture
User offline. Last seen 3 days 13 hours ago. Offline
Joined: 06/23/2008
Posts: 457
Re: How to display more than two lines of error message

why don't you use MsgGetText and MsgGetExplainText function to get the text you need into a string variable and then using messagebox to show it to the user.

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

Guest's picture
Guest (not verified)
Re: How to display more than two lines of error message

i have written the code as shown below

&str = MsgGetExplainText(25000, 251, "Message not found");

Error (MsgGet(25000, 251, "Message not found") | " " | &str);

but iam getting error message like
error compensation comp frequency has been changed,you must enter a proposed rate
you must enter a proposed rate
the message which i have given in explain text is coming two times.
first it is concatinated with message text in message catalogue and again below explanation is getting

this is sample error message i have given ,but my error message is too long

please let me know your comments

accasey's picture
User offline. Last seen 32 weeks 3 days ago. Offline
Joined: 06/12/2009
Posts: 5
Re: How to display more than two lines of error message

I thought the MsgGet function would display the Message & the Explanation? Not sure you need the MsgGetExplainText().

Ashar's picture
User offline. Last seen 3 weeks 6 days ago. Offline
Joined: 03/26/2008
Posts: 148
Re: How to display more than two lines of error message

You can try this,

&sError = "Your longer error message here";
MessageBox(%MsgStyle_OK, "Error", 0, 0, &sError);
Return;

/Ashar

Guest's picture
Guest (not verified)
Re: How to display more than two lines of error message

Thank you

Post new comment

The content of this field is kept private and will not be shown publicly.
CAPTCHA
The question below is to prevent automated spam submissions.
3 + 13 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.