Application WorkbookBeforeClose Event

Purpose

Occurs immediately before any open workbook closes.

Syntax

WorkbookBeforeClose(Wb, Cancel)

Required Parameters

Wb

The workbook that's being closed

Cancel

False when the event occurs. If the event procedure sets this argument to True, the workbook doesn't close when the procedure is finished.