Close Event

Applies To

AppointmentItem object, ContactItem object, JournalItem object, MailItem object, MeetingRequestItem object, NoteItem object, PostItem object, RemoteItem object, ReportItem object, TaskItem object, TaskRequestItem object.

Description

Occurs when the inspector associated with an Outlook item is being closed. If you set the return value of this function to False, the close operation isn't completed and the inspector is left open.

Syntax

Function Item_Close( )

See Also

CustomAction event, CustomPropertyChange event, Forward event, Open event, PropertyChange event, Read event, Reply event, ReplyAll event, Send event, Write event.

Example

This example automatically saves an item without prompting the user when the item closes.

Function Item_Close()
    If not myItem.Saved Then
        myItem.Save
    End If
End Function