Customizing event message
You can customize messages that are displayed in events. The message must consist of string literals, built-in macros, and the elements provided in the search string.
Built-in macros
You can use built-in macros to customize messages for text as well as XML instances.
Macro  | Description  | 
|---|---|
%FILENAME%  | Displays the log file full path  | 
%SEARCHID%  | Displays the search identifier  | 
%INSTANCE%  | Displays the name of the LOGMON instance  | 
%APPCLASS%  | Displays class name of an instance  | 
%PARAMETER%  | Displays the parameter name  | 
%LOGICALNAME%  | Displays the logical name  | 
%x  | For text instances, %x displays the xth word or column from the matched string in the text instance, where x is a number. For XML instances, %x displays the xth element from the matched string in the XML instance, where x is an element.  | 
%x-y  | Displays the x through y columns from the matched string in a text instance, where x and y are numbers  | 
Elements
The custom event displays only the element content or attribute values that are present in the search string. Thus, a custom event message is a subset of the search string result.
Thus, %x displays content of the xth element when there is a match from the respective search string. For example, suppose that the XML search string is as follows:
 <rec><vm>log_server</vm><level>SEVERE</level><class>com.bmc.log.XmlReader</class></rec>
To get the content of the <vm> element in the event, the custom event should include %1, where %1 is substituted with the content of the second element (that is, <vm>). Thus, %1 corresponds to the <vm> element, %2 corresponds to the <level> element, and %3 corresponds to the <class> element and so on. The value increments with every element that is provided with some regular expression to match.
You can also specify a range of elements by using %x-y, where x and y are numbers. The %x-y includes the content of all the elements ranging from x to y, including both x and y, in the respective event. To include the content of all the elements from the match string, you can provide %1- in the custom event message.
String literals
You can also add constant string literals in the custom event message. For example, you can use the following text:
 The book name is %1.