ReturnCode A value indicating how the window was exited. The default is %%RetCancel. This value can be accessed using the macro %%RetCode.
Parameters The name of an array. Hide A flag which, if true, causes the window to be hidden but not destroyed.
%%Cancel causes return from a window. The window is closed and destroyed. A ReturnCode may be passed back to the calling window, where it may be inspected using the macro %%RetCode. The default value for ReturnCode is %%RetCancel, which is the only indication that a %%Cancel has been performed. This value may be overridden.
The parameter Parameters may be the name of an array. If this is the case, the contents of the array specified as the parameter Parameters in the macro %%Cancel will be merged into the array specified as the parameter Parameters in the corresponding macro %%DoWin or %%OpenWin. Using this mechanism, it will be possible to return values to the calling environment, without needing to know the actual or formal name of the array being used.
If Hide is true, the window is hidden but not destroyed. This allows faster future reuse through bypassing the need for when reuse is likely.
For closing the current window, the macros %%Cancel and %%Return are the most appropriate.
For closing other windows, non-modal ones that were opened using %%OpenWin, or modal ones that used the option Hide when a %%Cancel or %%Return was executed, the macro %%CloseWin is the most appropriate.
The macro %%KillWin should only be used for windows that were created by other software than the MSM ViEW-Builder, e.g. by directly merging structures into ^$Window, or by using the macro %%MergeWin.
%%Cancel(,temp)
When the second parameter is present,
the contents of the array mentioned in this parameter will be
merged into the parameter-array that was specified whtn the window
was invoked.