This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.
MainView Console Automation for zEnterprise
MVCM MVCA MainView Console Management for zEnterprise MainView Console Automation for zEnterprise
How do you add the Clear action to the Right-Click menu for an MVCM Automation Viewer Priority Area message. Also, how do you remove a message from the MVCM Automation Viewer Priority Area?
Create the notifyRdDel RDL2 filter and the clearPAmsg function below. Note: These RDL2 rules are attached to this Knowledge Article in the ZIP file ClearPAMessages.zip. Instructions for importing these rules follow the description of the rules.
The notifyRdDel filter below moves RED and WHITE console messages to the MVCM Automation Viewer Priority Area. Lines 25 and 26 add an "Actions" menu item to the Right-Click menu in the viewer which will contain a Delete Message item.
The notifyRdDel filter is below:
// Trigger: notifyRdDel
// This function marks all WHITE messages as being permanent
// messages. A monitor is established and clearRd is called
// when the message scrolls of the screen or changes color.
// "Delete Message" option is added to the rule so user can
// manually delete it from the priority area pane
// See Also:
// clearRd, clearPAmsg
// Copyright (c) 2019, BMC Software, Inc.
trigger on message.COLOR == WHITE || message.COLOR == RED
// Add Actions - Delete Message menu item to right-click menu
// in the MVCA viewer. Delete Message will delete a selected
// message from the priority area pane
message.COMMANDS.DESCRIPTION = "Delete Message"
message.COMMANDS.FUNCTION = "do clearPAmsg(\"" & message.ID & "\")"
Right-clicking on a message in the Priority Area, and selecting Actions - Delete Message will call the clearPAmsg RDL2 function, which will remove the selected message from the MVCM Automation viewers Priority Area.
The clearPAmsg function is below:
i = PERMANENT_MESSAGES.size() - 1
do while i >= 0
if PERMANENT_MESSAGES[i].ID == msgid then
i = -1
i = i - 1
The result can be seen in the MVCM Automation viewer window below: