Workbook Events

Include Protected Members
Include Inherited Members

The Workbook type exposes the following members.

Events

  Name Description
Public event ActivateEvent Occurs when the workbook is activated.
Public event AddinInstall Occurs when the workbook is installed as an add-in.
Public event AddinUninstall Occurs when the workbook is uninstalled as an add-in.
Public event AfterSave Occurs after the workbook is saved.
Public event AfterXmlExport Occurs after Microsoft Office Excel saves or exports data from the workbook to an XML data file.
Public event AfterXmlImport Occurs after an existing XML data connection is refreshed or after new XML data is imported into the workbook.
Public event BeforeClose Occurs before the workbook closes. If the workbook has been changed, this event occurs before the user is asked to save changes.
Public event BeforePrint Occurs before the workbook (or anything in it) is printed.
Public event BeforeSave Occurs before the workbook is saved.
Public event BeforeXmlExport Occurs before Microsoft Office Excel saves or exports data from the workbook to an XML data file.
Public event BeforeXmlImport Occurs before an existing XML data connection is refreshed or before new XML data is imported into the workbook.
Public event BindingContextChanged Infrastructure.
Public event Deactivate Occurs when the workbook is deactivated.
Public event Disposed Represents the method that handles the Disposed event of a component. (Inherited from IComponent.)
Public event New Occurs when a new workbook is created.
Public event NewChart Occurs when a new chart is created in the workbook.
Public event NewSheet Occurs when a new sheet is created in the workbook.
Public event Open Occurs when the workbook is opened.
Public event PivotTableCloseConnection Occurs after a PivotTable report closes the connection to its data source.
Public event PivotTableOpenConnection Occurs after a PivotTable report opens the connection to its data source.
Public event RowsetComplete Occurs when the user navigates through the recordset or invokes the rowset action on an OLAP PivotTable.
Public event SheetActivate Occurs when any sheet is activated.
Public event SheetBeforeDoubleClick Occurs when any worksheet is double-clicked, before the default double-click action.
Public event SheetBeforeRightClick Occurs when any worksheet is right-clicked, before the default right-click action.
Public event SheetCalculate Occurs after any worksheet is recalculated or after any changed data is plotted on a chart.
Public event SheetChange Occurs when cells in any worksheet are changed by the user or by an external link.
Public event SheetDeactivate Occurs when any sheet is deactivated.
Public event SheetFollowHyperlink Occurs when you click any hyperlink in a workbook.
Public event SheetPivotTableAfterValueChange Occurs after a cell or range of cells inside a PivotTable are edited or recalculated (for cells that contain formulas).
Public event SheetPivotTableBeforeAllocateChanges Occurs before changes are applied to a PivotTable.
Public event SheetPivotTableBeforeCommitChanges Occurs before changes are committed against the OLAP data source for a PivotTable..
Public event SheetPivotTableBeforeDiscardChanges Occurs before changes to a PivotTable are discarded.
Public event SheetPivotTableChangeSync Occurs after changes to a PivotTable.
Public event SheetPivotTableUpdate Occurs after the sheet of a PivotTable report has been updated.
Public event SheetSelectionChange Occurs when the selection changes on any worksheet. Does not occur if the selection is on a chart sheet.
Public event Shutdown Occurs when the workbook host item shuts down.
Public event Startup Occurs after the workbook is running and all the initialization code in the assembly has been run.
Public event SyncEvent Occurs when the local copy of a worksheet that is part of a Document Workspace is synchronized with the copy on the server.
Public event WindowActivate Occurs when any workbook window is activated.
Public event WindowDeactivate Occurs when any workbook window is deactivated.
Public event WindowResize Occurs when any workbook window is resized.

Top

See Also

Reference

Workbook Interface

Microsoft.Office.Tools.Excel Namespace