Displays warning messages.
Msg( Message [ , nowait | status ] )
Where:
Message
The message to be displayed. It can be constant or stored in a variable. It is possible to add newlines in the string.
Mode
There are two modes to display the message, each one with a constant value associated:
Stores the message in an internal variable and processing continues. The user will not see the message until program processing ends. This improves program performance as less screen input/output is required.
For SD applications works as a "toast message".
The message is displayed at the moment when it is originated. It is useful for giving the user information about program processing status.
Objects: Procedure, Transaction,Web Panel , Panel, Work With for Smart Devices
Generators: Apple, Android, .NET, Java
- This message option degrades performance due to the required screen input/output.
- It is used to display the literal, variable, or character expression contents in the message popup window (or message line, depending on the working environment).
The moment when the user actually sees the message will depend on where the command is declared and on the option selected.
- When using a variable, GeneXus controls, at specification time, that the variable type is Character.
- When Mode option is not specified:
- Web Panels and Transactions
Sends the message and waits for the Enter key to be pressed.
- Procedures
See status option.
- Smart Devices
The message command has no effect in Start, Refresh and Load events from a Smart Device application as it is considered a Client-side event.
Msg("Hello user." + newline() + "And on this line I say: good day to you")
Msg(&Today)
Msg(Format('B: %1', B)) // Where B is Character type
Msg(Concat('Entered Date: ', DtoC(C))) // Where C is Date type.
Msg(Concat('Entered Date Hour', TtoC(D))) // Where and D is Datetime type.
&var = "Hello user." + newline() + "And on this line I say: good day to you"
Msg(&var, nowait) // Where &var is character type
Msg rule
Client-side Events in Native Mobile Applications
Server-side Events in Native Mobile Applications