Please enable JavaScript to view this site.

Navigation: Advanced topics > Events > Sample events > Appearance

Change the message after the record was added or saved

Scroll Prev Next More

 

To change the message, use the following code in the AfterAdd, AfterEdit or BeforeDisplay events:

Example 1

Change the error message in case of the error. You can do this in BeforeDisplay event.

 

if( $pageObject->messageType == MESSAGE_ERROR ) {
  $pageObject->setMessage("My error message");
}

 

This is how the result looks like:

change_message

Example 2

Change the 'success' message:

$pageObject->setMessageType(MESSAGE_INFO);
$pageObject->setMessage("The data was successfully saved");

 

See also:

Grid Row JavaScript API: row.setMessage()

RunnerPage object

Error reporting

Display a message on the Web page

Master-details relationship between tables

 

Created with Help+Manual 7 and styled with Premium Pack Version 3 © by EC Software