RemoveCurrentWatch command

From m204wiki
Revision as of 23:23, 3 February 2023 by Ekern (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Action:

Removes the currently selected Watch Window item. If there is no currently selected item, it does nothing.

The current selected item may simply be the last added or clicked line (and not highlighted), or it may be a highlighted line as the result of a search or location (top or bottom) command.

Using removeCurrentWatch to remove a watched item is essentially the same operation as right clicking an item and selecting Remove from the context menu.

Syntax:

removeWatch 

This "removeWatch" macro is an example of using the command:

# RemoveWatch.macro  
#
# Usage: removeWatch varName  
# where varName is name of watched variable to remove 
# as it appears in the Watch Window. 
# For example, removeWatch %j 
#
# See if it is watched. If not, done: 
in watchWindow searchFromTop &argstring 
continueMacroIf &&searchSuccess 
#
# It was watched, so remove and report: 
removeCurrentWatch
echo &&concatenate("removed watch ", &argstring) 

Client menu: --
Introduced: Build 58