CloseSynchron Method (IMoveable)

Class

IMoveable.

Action

Closes the window and waits until the window is closed.

The method attempts to close the window by trying the following events, in this sequence, stopping when the window closes:
  1. Call the close() method on the window.
  2. If the window is a dialog, type the keys specified in the option OPT_CLOSE_DIALOG_KEYS and wait one second for the dialog to close.
  3. If there is a single button in the window, click that button.
  4. If the closeConfirm parameter is set to true: Click the list of buttons specified with the option OPT_CLOSE_WINDOW_BUTTONS.
  5. Select the menus specified with option OPT_CLOSE_WINDOW_MENUS.
  6. Use Alt+F4.

Syntax

iMoveable.CloseSynchron([closeConfirm])
Variable Description
closeConfirm Optional: Specifies whether to close confirmation dialogs that may pop up when closing the window, for example a 'Save changes' dialog. Use true to close confirmation dialogs and false to raise an exception if a confirmation dialog pops up. If set to true the value of the option OPT_CLOSE_CONFIRM_BUTTONS is used to determine which button to select in order to close confirmation dialogs. Boolean.