Close Event

Close Event

See Also         Example         Applies To

Occurs when the Inspector associated with an Outlook item is being closed.

Syntax 1

Function Item_Close()

Syntax 2

Sub object_Close(Cancel as Boolean)

object   An expression that evaluates to an object in the “Applies To” list.

Cancel   Optional. False when the event occurs. If the event procedure sets this argument to True, the close operation is not completed and the inspector is left open.

Remarks

Use Syntax 1 in VBScript. If you set the return value of this function to False, the close operation isn't completed and the inspector is left open.

Use Syntax 2 when handling the Close event in Visual Basic or Visual Basic for Applications.