From Clomosy Docs

(Created page with " procedure ShowMessage(const Text string); Applications or the operating system itself use message windows to warn or inform the user. Message windows can be created in clomosy applications using ShowMessage.<br> In simple terms, it is a message window that can be used to inform the user. It has only one parameter that receives the message to be displayed on the screen. The title of the window is the project name. There is no option to click other than the OK button. T...")
 
No edit summary
Line 7: Line 7:


'''Example:'''<br>
'''Example:'''<br>
:'''Base Syntax'''
  '''begin'''<br>
  '''begin'''<br>
   // Show a simple message
   // Show a simple message
   ShowMessage('Hello World');<br>
   ShowMessage('Hello World');<br>
   // Show a blank message
   // Show a blank message
   ShowMessage('');<br>
   ShowMessage(<nowiki>''</nowiki>);<br>
   // Split this into two lines
   // Split this into two lines
   ShowMessage('Hello '+#13#10+'World');<br>
   ShowMessage('Hello '+#13#10+'World');<br>
  '''end;'''
  '''end;'''
:'''TRObject Syntax'''
  {
  // Show a simple message
  ShowMessage('Hello World');
 
  // Show a blank message
  ShowMessage(<nowiki>''</nowiki>);
 
  // Split this into two lines
  ShowMessage('Hello '+#13#10+'World');
  }


'''Output:'''<br>
'''Output:'''<br>

Revision as of 10:13, 13 February 2024

procedure ShowMessage(const Text string);

Applications or the operating system itself use message windows to warn or inform the user. Message windows can be created in clomosy applications using ShowMessage.
In simple terms, it is a message window that can be used to inform the user. It has only one parameter that receives the message to be displayed on the screen. The title of the window is the project name. There is no option to click other than the OK button. The message window is displayed in the middle of the screen.

Insert carriage return and line feed characters (#13#10) into the string to generate multi line message display.

Example:

Base Syntax
begin
// Show a simple message ShowMessage('Hello World');
// Show a blank message ShowMessage('');
// Split this into two lines ShowMessage('Hello '+#13#10+'World');
end;
TRObject Syntax
 {
  // Show a simple message
  ShowMessage('Hello World');
 
  // Show a blank message
  ShowMessage('');
 
  // Split this into two lines
  ShowMessage('Hello '+#13#10+'World');
 }

Output:

Output1: Hello World
Output2:
Output3: Hello
         World