Welcome! Log In Create A New Profile

Advanced

Message Box

Posted by Cherry 
Cherry
Message Box
May 31, 2008 04:14AM

Hello everyone,

If anyone knows how to use parameter in message box. For example I want to write the same staff like: "Please enter: " many places in the program then when I write the message box I send the parameter after "Please enter:". Is it possible to do this? if so please tell me how to do.
Leo Voet
Re: Message Box
May 31, 2008 11:40AM

Maybe this is what you mean ?

Procedure MyMessage(pTxt)

Info("Pease enter: " + pTxt)



Call in your program:

If Edt_Name = "" THEN
MyMessage("Name")
END


Is this what you want to do ?
Ricardo
Re: Message Box
June 02, 2008 01:44AM
Nice tips...........

Thank you too:rp:
Cherry
Re: Message Box
June 02, 2008 06:25AM
Hi LeoVote,

Thanks for your reply.

I would like to store several messages to a resource file but I don't know where to keep those messages in Windev that allow me to call them to use, Here are some messages example:

- %1 is required.
- Are you sure to %1?
- %1 is invalid.
- %1 must be earlier than %2.

Where: %1, %2 are parameters

I want to use above messages and pass the parameter to it, Is it possible to do like this in Windev? As I don't want to write the same message many times.

Thanks in advance,

Have a good day,

Cherry



Leo
Re: Message Box
June 02, 2008 02:49PM
The Windev function BuildString() does exactly what you want.
You'll find it in the manual and in the help.

Art Bonds
Re: Message Box
June 02, 2008 03:25PM
> I would like to store several messages to a resource file

Use a hyperfile or XML file. Write a small Global Procedure that you can pass parms to.

Leo
Re: Message Box
June 02, 2008 03:27PM
... sorry, StringBuild() it is.
(ou ChaîneConstruit() en Français)
Cherry
Re: Message Box
June 03, 2008 05:08AM

Thanks for your replies. I'll try to do and will let you know

Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: