RemoveMinimizeWatch Method
This method disables minimize "watching" of the window (form) passed in. When the user presses the minimize button on the "watched" form, the window will no longer zoom to the system tray instead.
Syntax
csSysTray[(index)].RemoveMinimizeWatch hWnd
The RemoveMinimizeWatch method syntax has these parts:
Part | Description |
csSysTray | The SysTray control you are working with, or a control array of SysTray controls. |
hWnd | A handle to the form you want to stop being watched. (ex: Form1.hWnd) |
Examples
Example 1 (Ending a Minimize Watch on a form)
csSysTray1.RemoveMinimizeWatch Form1.hWnd
Remarks
You probably want to set the ShowInTaskBar property of the forms you are watching to False at design time. See also the AddMinimizeWatch method.
Also, the Microsoft Windows operating environment identifies each form and control in
an application by assigning it a handle, or hWnd. The hWnd property is used with Windows
API calls. Many Windows operating environment functions require the hWnd of the active
window as an argument.
Note Because the value of this property can change while a program is
running, never store the hWnd value in a variable.