Kbase P26936: How to catch "X button pressed" in Windows
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  6/12/2003 |
|
Status: Unverified
GOAL:
How to catch "X button pressed" in Windows
FACT(s) (Environment):
Progress 9.x
FACT(s) (Environment):
Windows
FIX:
No matter what are you using, SmartWindow or Window when user presses X button on the upper right corner, "WINDOW-CLOSE" trigger is fired.
In order to initiate any action on that event your code must be placed before APPLY "CLOSE" TO THIS-PROCEDURE statement.
Example:
ON WINDOW-CLOSE OF cwin
DO:
RUN myproc. /* my code here */
APPLY "CLOSE":U TO THIS-PROCEDURE.
RETURN NO-APPLY.
END.