Export (0) Print
Expand All

Workbook Interface

Represents a workbook in Excel projects created by using the Office development tools in Visual Studio.

Namespace:  Microsoft.Office.Tools.Excel
Assemblies:   Microsoft.Office.Tools.Excel (in Microsoft.Office.Tools.Excel.dll)
  Microsoft.Office.Tools.Excel.v4.0.Utilities (in Microsoft.Office.Tools.Excel.v4.0.Utilities.dll)

'Declaration
<GuidAttribute("b74cbb86-9c9f-4172-9ae7-3ce4a7bfa5eb")> _
Public Interface Workbook _
	Inherits IBindableComponent, IComponent, IDisposable, ISupportInitialize

The Workbook type exposes the following members.

  NameDescription
Public property_CodeNameInfrastructure.
Public property_ReadOnlyRecommendedInfrastructure.
Public propertyAcceptLabelsInFormulasGets or sets a value that indicates whether labels can be used in worksheet formulas.
Public propertyAccuracyVersionSpecifies whether certain worksheet functions use the latest accuracy algorithms to calculate their results.
Public propertyActiveChartGets a Microsoft.Office.Interop.Excel.Chart object that represents the active chart (either an embedded chart or a chart sheet). An embedded chart is considered active when it is either selected or activated. When no chart is active, this property returns Nothing.
Public propertyActiveSheetGets the active sheet (the sheet on top).
Public propertyActiveSlicerGets an object that represents the active slicer in the active workbook or in the specified workbook.
Public propertyApplicationGets an Microsoft.Office.Interop.Excel.Application that represents the creator of the workbook.
Public propertyAuthorGets or sets the author of the workbook.
Public propertyAutoUpdateFrequencyGets or sets the number of minutes between automatic updates to the shared workbook.
Public propertyAutoUpdateSaveChangesGets or sets a value that indicates whether current changes to the shared workbook are posted to other users whenever the workbook is automatically updated.
Public propertyBindingContextGets or sets the collection of currency managers for the IBindableComponent. (Inherited from IBindableComponent.)
Public propertyBuiltinDocumentPropertiesGets a Microsoft.Office.Core.DocumentProperties collection that represents all the built-in document properties for the workbook.
Public propertyCalculationVersionGets a number that indicates the version of Excel that the workbook was last fully recalculated by. The rightmost four digits are the minor calculation engine version number, and the other digits (on the left) are the major version of Microsoft Office Excel.
Public propertyChangeHistoryDurationGets or sets the number of days shown in the shared workbook's change history.
Public propertyChartsGets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the chart sheets in the workbook.
Public propertyCheckCompatibilityGets or sets a value that indicates whether to run the compatibility checker automatically when the workbook is saved.
Public propertyCodeNameInfrastructure.
Public propertyColorsGets or sets colors in the palette for the workbook.
Public propertyCommandBarsGets a Microsoft.Office.Core.CommandBars object that represents the Microsoft Office Excel command bars.
Public propertyCommentsGets or sets the comments attached to the workbook.
Public propertyConflictResolutionGets or sets the way conflicts are to be resolved whenever a shared workbook is updated.
Public propertyConnectionsGets the collection of connections between the workbook and a data source.
Public propertyConnectionsDisabledGets a value that indicates whether to disable the external connections or links in the workbook.
Public propertyContainerGets the object that represents the container application for the workbook.
Public propertyContentTypePropertiesGets a collection of properties that describe metadata that is stored in the workbook.
Public propertyCreateBackupGets a value that indicates whether a backup file is created when this file is saved.
Public propertyCreatorGets the application in which the workbook was created.
Public propertyCustomDocumentPropertiesGets a Microsoft.Office.Core.DocumentProperties collection that represents all the custom document properties for the workbook.
Public propertyCustomViewsGets a Microsoft.Office.Interop.Excel.CustomViews collection that represents all the custom views for the workbook.
Public propertyCustomXMLPartsGets the collection of custom XML parts in the workbook.
Public propertyDataBindingsGets the collection of data-binding objects for this IBindableComponent. (Inherited from IBindableComponent.)
Public propertyDataHostInfrastructure.
Public propertyDate1904Gets or sets a value that indicates whether the workbook uses the 1904 date system.
Public propertyDefaultExtensionGets the default extension for this Workbook object.
Public propertyDefaultPivotTableStyleGets or sets the table style from the TableStyles property that is used as the default style for PivotTable reports in the workbook.
Public propertyDefaultSlicerStyleGets or sets the style from the TableStyles object that is used as the default style for slicers.
Public propertyDefaultTableStyleGets or sets the table style from the TableStyles property that is used as the default style for tables in the workbook.
Public propertyDialogSheetsIncluded for backwards compatibility only.
Public propertyDisplayDrawingObjectsGets or sets how shapes are displayed.
Public propertyDisplayInkCommentsGets or sets a value that indicates whether ink comments are displayed in the workbook.
Public propertyDocumentInspectorsGets the collection of Document Inspector modules for the workbook.
Public propertyDocumentLibraryVersionsGets a Microsoft.Office.Core.DocumentLibraryVersions collection that represents the collection of versions of a shared workbook that has versioning enabled and that is stored in a document library on a server.
Public propertyDoNotPromptForConvertGets or sets a value that indicates whether to prompt the user to convert the workbook if it contains features that are not supported by versions of Excel earlier than Excel 2007.
Public propertyEnableAutoRecoverGets or sets a value that indicates whether Microsoft Office Excel saves changed files, of all formats, on a timed interval.
Public propertyEncryptionProviderGets or sets the name of the algorithm encryption provider that Microsoft Office Excel uses when encrypting documents.
Public propertyEnvelopeVisibleGets or sets a value that indicates whether the e-mail composition header and the envelope toolbar are both visible.
Public propertyExcel4IntlMacroSheetsGets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the Microsoft Office Excel 4.0 international macro sheets in the workbook.
Public propertyExcel4MacroSheetsGets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the Microsoft Office Excel 4.0 macro sheets in the workbook.
Public propertyExcel8CompatibilityModeGets a value that indicates whether the workbook is in compatibility mode.
Public propertyExtensionGets a custom extension for this Workbook object.
Public propertyFileFormatGets the file format and type of the workbook.
Public propertyFinalGets or sets a value that indicates whether the workbook is final.
Public propertyForceFullCalculationGets or sets a value that indicates whether to force a full calculation of a workbook.
Public propertyFullNameGets the name of the object, including its path on disk.
Public propertyFullNameURLEncodedGets the name of the object, including its path on disk.
Public propertyHasMailerInfrastructure.
Public propertyHasPasswordGets a value that indicates whether the workbook has a protection password.
Public propertyHasRoutingSlipGets or sets a value that indicates whether the workbook has a routing slip.
Public propertyHasVBProjectGets a value that indicates whether a workbook has an attached Microsoft Visual Basic for Applications (VBA) project.
Public propertyHighlightChangesOnScreenGets or sets a value that indicates whether changes to the shared workbook are highlighted on screen.
Public propertyHostContextInfrastructure.
Public propertyHTMLProjectGets the Microsoft.Office.Core.HTMLProject in the workbook, which represents a top-level project branch.
Public propertyIconSetsGets the collection of built-in icon sets that can be used to apply a conditional formatting rule to a range in the workbook.
Public propertyInactiveListBorderVisibleGets or sets a value that indicates whether list borders are visible when a list is not active.
Public propertyInnerObjectGets a Microsoft.Office.Interop.Excel.Workbook that represents the underlying native object for the Workbook.
Public propertyIsAddinGets or sets a value that indicates whether the workbook is running as an add-in.
Public propertyIsInplaceGets a value that indicates whether the specified workbook is being edited in place.
Public propertyItemProviderInfrastructure.
Public propertyKeepChangeHistoryGets or sets a value that indicates whether change tracking is enabled for the shared workbook.
Public propertyKeywordsGets or sets the keywords attached to the workbook.
Public propertyListChangesOnNewSheetGets or sets a value that indicates whether changes to the shared workbook are shown on a separate worksheet.
Public propertyMailerInfrastructure.
Public propertyModulesIncluded for backwards compatibility only.
Public propertyMultiUserEditingGets a value that indicates whether the workbook is open as a shared list.
Public propertyNameGets the name of the workbook.
Public propertyNamesGets a Microsoft.Office.Interop.Excel.Names collection that represents all the names in the workbook (including all worksheet-specific names).
Public propertyOnSaveIncluded for backwards compatibility only.
Public propertyOnSheetActivateIncluded for backwards compatibility only.
Public propertyOnSheetDeactivateIncluded for backwards compatibility only.
Public propertyParentGets the parent object for the workbook.
Public propertyPasswordGets or sets the password that must be supplied to open the workbook.
Public propertyPasswordEncryptionAlgorithmGets the algorithm that Microsoft Office Excel uses to encrypt passwords for the workbook.
Public propertyPasswordEncryptionFilePropertiesGets a value that indicates whether Microsoft Office Excel encrypts file properties for the specified password-protected workbook.
Public propertyPasswordEncryptionKeyLengthGets the key length of the algorithm that Microsoft Office Excel uses when encrypting passwords for the workbook.
Public propertyPasswordEncryptionProviderGets the name of the algorithm encryption provider that Microsoft Office Excel uses when encrypting passwords for the workbook.
Public propertyPathGets the complete path to the application, excluding the final separator and name of the application.
Public propertyPermissionGets a Microsoft.Office.Core.Permission object that represents the permission settings in the workbook.
Public propertyPersonalViewListSettingsGets or sets a value that indicates whether filter and sort settings for lists are included in the user's personal view of the shared workbook.
Public propertyPersonalViewPrintSettingsGets or sets a value that indicates whether print settings are included in the user's personal view of the shared workbook.
Public propertyPrecisionAsDisplayedGets or sets a value that indicates whether calculations in this workbook will be done using only the precision of the numbers as they are displayed.
Public propertyProtectStructureGets a value that indicates whether the order of the sheets in the workbook is protected.
Public propertyProtectWindowsGets a value that indicates whether the windows of the workbook are protected.
Public propertyPublishObjectsGets the Microsoft.Office.Interop.Excel.PublishObjects collection.
Public propertyReadOnlyGets a value that indicates whether the workbook has been opened as read-only.
Public propertyReadOnlyRecommendedGets or sets a value that indicates whether the workbook was saved as read-only recommended.
Public propertyRemovePersonalInformationGets or sets a value that indicates whether personal information can be removed from the workbook.
Public propertyResearchGets an object that represents the research service for the workbook.
Public propertyRevisionNumberGets the number of times the workbook has been saved while open as a shared list. If the workbook is open in exclusive mode, this property returns 0 (zero).
Public propertyRoutedGets a value that indicates whether the workbook has been routed to the next recipient.
Public propertyRoutingSlipGets a Microsoft.Office.Interop.Excel.RoutingSlip object that represents the routing slip for the workbook.
Public propertySavedGets or sets a value that indicates whether no changes have been made to the workbook since it was last saved.
Public propertySaveLinkValuesGets or sets a value that indicates whether Microsoft Office Excel saves external link values with the workbook.
Public propertyServerPolicyGets an object that represents a policy specified for a workbook that is stored on a server running Microsoft Office SharePoint Server.
Public propertyServerViewableItemsGets an object that you can use to interact with the list of published objects in the workbook that are shown on a Microsoft Office SharePoint Server server.
Public propertySharedWorkspaceGets a Microsoft.Office.Core.SharedWorkspace that represents the Document Workspace in which the workbook is located.
Public propertySheetsGets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the sheets in the workbook.
Public propertyShowConflictHistoryGets or sets a value that indicates whether the Conflict History worksheet is visible in the workbook that is open as a shared list.
Public propertyShowPivotChartActiveFieldsGets or sets a value that indicates whether the PivotChart Filter Pane is visible.
Public propertyShowPivotTableFieldListGets or sets a value that indicates whether the PivotTable field list can be shown.
Public propertySignaturesGets the collection of digital signatures for the workbook.
Public propertySiteGets or sets the ISite associated with the IComponent. (Inherited from IComponent.)
Public propertySlicerCachesGets the SlicerCaches object associated with the workbook.
Public propertySmartDocumentGets a Microsoft.Office.Core.SmartDocument that represents the settings for a smart document solution.
Public propertySmartTagOptionsGets a Microsoft.Office.Interop.Excel.SmartTagOptions object representing the options that can be performed with a smart tag. This type or member is intended to be used only in projects for the 2007 Microsoft Office system. Smart tags are deprecated in Office 2010.
.
Public propertyStylesGets a Microsoft.Office.Interop.Excel.Styles collection that represents all the styles in the workbook.
Public propertySubjectGets or sets the subject for the mailer or routing slip.
Public propertySyncGets a Microsoft.Office.Core.Sync object that provides access to the methods and properties of documents that are part of a Document Workspace.
Public propertyTableStylesGets the collection of table styles that are used in the workbook.
Public propertyTagGets or sets the object that contains data about the workbook.
Public propertyTemplateRemoveExtDataGets or sets a value that indicates whether external data references are removed when the workbook is saved as a template.
Public propertyThemeGets the theme that is applied to the workbook.
Public propertyTitleGets or sets the title of the Web page when the workbook is saved as a Web page.
Public propertyUpdateLinksGets or sets a value that indicates a workbook's setting for updating embedded OLE links.
Public propertyUpdateRemoteReferencesGets or sets a value that indicates whether Microsoft Office Excel updates remote references in the workbook.
Public propertyUserControlGets or sets a value that indicates whether the workbook or application was created or opened by the user.
Public propertyUserStatusGets a 1-based, two-dimensional array that provides information about each user who has the workbook open as a shared list.
Public propertyVBASignedGets a value that indicates whether the Visual Basic for Applications project for the workbook has been digitally signed.
Public propertyVBProjectGets the virtual Microsoft.Vbe.Interop.VBProject project that is in the workbook.
Public propertyVstoSmartTagsGets the Microsoft.Office.Tools.SmartTagCollection associated with the workbook. This type or member is intended to be used only in projects for the 2007 Microsoft Office system. Smart tags are deprecated in Office 2010.
.
Public propertyWebOptionsGets the Microsoft.Office.Interop.Excel.WebOptions collection, which contains workbook-level attributes used by Microsoft Office Excel when you save a document as a Web page or open a Web page.
Public propertyWindowsGets a Microsoft.Office.Interop.Excel.Windows collection that represents all the windows in the workbook.
Public propertyWorksheetsGets a Microsoft.Office.Interop.Excel.Sheets collection that represents all the worksheets in the workbook.
Public propertyWritePasswordGets or sets the write password of a workbook.
Public propertyWriteReservedGets a value that indicates whether the workbook is write-reserved.
Public propertyWriteReservedByGets the name of the user who currently has write permission for the workbook.
Public propertyXmlMapsGets an Microsoft.Office.Interop.Excel.XmlMaps collection that represents the schema maps that have been added to the workbook.
Public propertyXmlNamespacesGets an Microsoft.Office.Interop.Excel.XmlNamespaces collection that represents the XML namespaces contained in the workbook.
Top

  NameDescription
Public method_PrintOutInfrastructure.
Public method_ProtectInfrastructure.
Public method_SaveAsInfrastructure.
Public method_VtblGap1_1Infrastructure.
Public method_VtblGap2_1Infrastructure.
Public method_VtblGap3_1Infrastructure.
Public method_VtblGap4_1Infrastructure.
Public method_VtblGap5_1Infrastructure.
Public method_VtblGap6_1Infrastructure.
Public method_VtblGap7_2Infrastructure.
Public methodAcceptAllChangesAccepts all changes in the shared workbook.
Public methodActivateActivates the first window associated with the workbook.
Public methodAddToFavoritesAdds a shortcut to the workbook to the Favorites folder.
Public methodApplyThemeApplies the specified theme to the workbook.
Public methodBeginInitSignals the object that initialization is starting. (Inherited from ISupportInitialize.)
Public methodBreakLinkConverts formulas linked to other Microsoft Office Excel sources or OLE sources to values.
Public methodCanCheckInGets a value that indicates whether Microsoft Office Excel can check in the workbook to a server.
Public methodChangeFileAccessChanges the access permissions for the workbook. This might require an updated version to be loaded from the disk.
Public methodChangeLinkChanges a link from one document to another.
Public methodCheckInReturns a workbook from a local computer to a server, and sets the local workbook to read-only so that it cannot be edited locally. Calling this method closes the workbook.
Public methodCheckInWithVersionSends the workbook from the local computer to a server, and sets the local workbook to read-only so that it cannot be edited locally. Calling this method closes the workbook.
Public methodCloseCloses the workbook.
Public methodDeleteNumberFormatDeletes a custom number format from the workbook.
Public methodDisposePerforms application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. (Inherited from IDisposable.)
Public methodDummy16Infrastructure.
Public methodDummy17Infrastructure.
Public methodDummy26Infrastructure.
Public methodDummy27Infrastructure.
Public methodEnableConnectionsEnables data connections within the workbook.
Public methodEndInitSignals the object that initialization is complete. (Inherited from ISupportInitialize.)
Public methodEndReviewTerminates a review of a file that has been sent for review using the SendForReview method.
Public methodExclusiveAccessAssigns the current user exclusive access to the workbook that is open as a shared list.
Public methodExportAsFixedFormatSaves a workbook in PDF or XPS format.
Public methodFollowHyperlinkDisplays a cached document, if it has already been downloaded. Otherwise, this method resolves the hyperlink, downloads the target document, and displays the document in the appropriate application.
Public methodForwardMailerInfrastructure.
Public methodget_ColorsInfrastructure. Use the Colors property instead of this method.
Public methodGetWorkflowTasksReturns the collection of workflow tasks for the workbook.
Public methodGetWorkflowTemplatesReturns the collection of workflow templates for the workbook.
Public methodHighlightChangesOptionsControls how changes are shown in a shared workbook.
Public methodLinkInfoGets the link date and update status.
Public methodLinkSourcesReturns an Array of links in the workbook.
Public methodLockServerFileLocks the workbook on the server to prevent modification.
Public methodMergeWorkbookMerges changes from one workbook into an open shared workbook.
Public methodNewWindowCreates a new window.
Public methodOpenLinksOpens the supporting documents for a link or links.
Public methodPivotCachesGets a Microsoft.Office.Interop.Excel.PivotCaches collection that represents all the PivotTable caches in the specified workbook.
Public methodPivotTableWizardCreates a Microsoft.Office.Interop.Excel.PivotTable object.
Public methodPostPosts the workbook to a public folder. This method works only with a Microsoft Exchange client connected to a Microsoft Exchange server.
Public methodPrintOutPrints the workbook.
Public methodPrintOutExPrints the workbook.
Public methodPrintPreviewShows a preview of the object as it would look when printed.
Public methodProtectProtects a workbook so that it cannot be modified.
Public methodProtectSharingSaves the workbook and protects it for sharing.
Public methodProtectSharingExSaves the workbook and protects it for sharing.
Public methodPurgeChangeHistoryNowRemoves entries from the change log for the workbook.
Public methodRecheckSmartTagsCauses a foreground smart tag check to occur automatically annotating data that was not annotated before. This type or member is intended to be used only in projects for the 2007 Microsoft Office system. Smart tags are deprecated in Office 2010.
.
Public methodRefreshAllRefreshes all external data ranges and PivotTable reports in the workbook.
Public methodRejectAllChangesRejects all changes in the shared workbook.
Public methodReloadAsReloads a workbook based on an HTML document, using the specified document encoding.
Public methodRemoveCustomizationRemoves the customization that was created by using Office development tools in Visual Studio from the workbook.
Public methodRemoveDocumentInformationRemoves all information of the specified type from the workbook.
Public methodRemoveUserDisconnects the specified user from the shared workbook.
Public methodReplyInfrastructure.
Public methodReplyAllInfrastructure.
Public methodReplyWithChangesSends an e-mail message to the author of a workbook that has been sent out for review, notifying him or her that a reviewer has completed review of the workbook.
Public methodResetColorsResets the color palette to the default colors.
Public methodRouteRoutes the workbook, using the workbook's current routing slip.
Public methodRunAutoMacrosRuns the Auto_Open, Auto_Close, Auto_Activate, or Auto_Deactivate macro attached to the workbook. This method is included for backward compatibility. You should use the Open, Close, Activate and Deactivate events instead of these macros.
Public methodSaveSaves changes to the workbook.
Public methodSaveAsSaves changes to the workbook in a different file.
Public methodSaveAsXMLDataExports the data that has been mapped to the specified XML schema map to an XML data file.
Public methodSaveCopyAsSaves a copy of the workbook to a file but does not modify the open workbook in memory.
Public methodsbltInfrastructure.
Public methodSendFaxOverInternetSends the active sheet in the workbook as a fax to the specified recipients.
Public methodSendForReviewSends a workbook in an e-mail message for review to the specified recipients.
Public methodSendMailSends the workbook by using the installed mail system.
Public methodSendMailerInfrastructure.
Public methodset_ColorsInfrastructure. Use the Colors property instead of this method.
Public methodSetLinkOnDataSets the name of a procedure that runs whenever a DDE link is updated.
Public methodSetPasswordEncryptionOptionsSets the options for encrypting the workbook using a password.
Public methodToggleFormsDesignToggles Microsoft Office Excel into and out of design mode.
Public methodUnprotectRemoves protection from the workbook. This method has no effect if the workbook is not protected.
Public methodUnprotectSharingTurns off protection for sharing and saves the workbook.
Public methodUpdateFromFileUpdates a read-only workbook from the saved disk version of the workbook if the disk version is more recent than the copy of the workbook that is loaded in memory. If the disk copy has not changed since the workbook was loaded, the in-memory copy of the workbook is not reloaded.
Public methodUpdateLinkUpdates a Microsoft Office Excel, DDE, or OLE link (or links).
Public methodWebPagePreviewDisplays a preview of the workbook as it would look if saved as a Web page.
Public methodXmlImportImports an XML data file into the current workbook.
Public methodXmlImportXmlImports an XML data stream that has been previously loaded into memory.
Top

  NameDescription
Public eventActivateEventOccurs when the workbook is activated.
Public eventAddinInstallOccurs when the workbook is installed as an add-in.
Public eventAddinUninstallOccurs when the workbook is uninstalled as an add-in.
Public eventAfterSaveOccurs after the workbook is saved.
Public eventAfterXmlExportOccurs after Microsoft Office Excel saves or exports data from the workbook to an XML data file.
Public eventAfterXmlImportOccurs after an existing XML data connection is refreshed or after new XML data is imported into the workbook.
Public eventBeforeCloseOccurs before the workbook closes. If the workbook has been changed, this event occurs before the user is asked to save changes.
Public eventBeforePrintOccurs before the workbook (or anything in it) is printed.
Public eventBeforeSaveOccurs before the workbook is saved.
Public eventBeforeXmlExportOccurs before Microsoft Office Excel saves or exports data from the workbook to an XML data file.
Public eventBeforeXmlImportOccurs before an existing XML data connection is refreshed or before new XML data is imported into the workbook.
Public eventBindingContextChangedInfrastructure.
Public eventDeactivateOccurs when the workbook is deactivated.
Public eventDisposedRepresents the method that handles the Disposed event of a component. (Inherited from IComponent.)
Public eventNewOccurs when a new workbook is created.
Public eventNewChartOccurs when a new chart is created in the workbook.
Public eventNewSheetOccurs when a new sheet is created in the workbook.
Public eventOpenOccurs when the workbook is opened.
Public eventPivotTableCloseConnectionOccurs after a PivotTable report closes the connection to its data source.
Public eventPivotTableOpenConnectionOccurs after a PivotTable report opens the connection to its data source.
Public eventRowsetCompleteOccurs when the user navigates through the recordset or invokes the rowset action on an OLAP PivotTable.
Public eventSheetActivateOccurs when any sheet is activated.
Public eventSheetBeforeDoubleClickOccurs when any worksheet is double-clicked, before the default double-click action.
Public eventSheetBeforeRightClickOccurs when any worksheet is right-clicked, before the default right-click action.
Public eventSheetCalculateOccurs after any worksheet is recalculated or after any changed data is plotted on a chart.
Public eventSheetChangeOccurs when cells in any worksheet are changed by the user or by an external link.
Public eventSheetDeactivateOccurs when any sheet is deactivated.
Public eventSheetFollowHyperlinkOccurs when you click any hyperlink in a workbook.
Public eventSheetPivotTableAfterValueChangeOccurs after a cell or range of cells inside a PivotTable are edited or recalculated (for cells that contain formulas).
Public eventSheetPivotTableBeforeAllocateChangesOccurs before changes are applied to a PivotTable.
Public eventSheetPivotTableBeforeCommitChangesOccurs before changes are committed against the OLAP data source for a PivotTable..
Public eventSheetPivotTableBeforeDiscardChangesOccurs before changes to a PivotTable are discarded.
Public eventSheetPivotTableChangeSyncOccurs after changes to a PivotTable.
Public eventSheetPivotTableUpdateOccurs after the sheet of a PivotTable report has been updated.
Public eventSheetSelectionChangeOccurs when the selection changes on any worksheet. Does not occur if the selection is on a chart sheet.
Public eventShutdownOccurs when the workbook host item shuts down.
Public eventStartupOccurs after the workbook is running and all the initialization code in the assembly has been run.
Public eventSyncEventOccurs when the local copy of a worksheet that is part of a Document Workspace is synchronized with the copy on the server.
Public eventWindowActivateOccurs when any workbook window is activated.
Public eventWindowDeactivateOccurs when any workbook window is deactivated.
Public eventWindowResizeOccurs when any workbook window is resized.
Top

A Microsoft.Office.Tools.Excel.Workbook object provides the same members as a Microsoft.Office.Interop.Excel.Workbook object from the Excel primary interop assembly, but it adds the following features:

In application-level projects, you can create Microsoft.Office.Tools.Excel.Workbook objects programmatically by using the GetVstoObject method. For more information, see Extending Word Documents and Excel Workbooks in Application-Level Add-ins at Run Time.

In document-level projects, you typically do not use Microsoft.Office.Tools.Excel.Workbook objects directly. Instead, use the ThisWorkbook class to programmatically access the workbook in your project. The ThisWorkbook class derives most of its members from the Microsoft.Office.Tools.Excel.WorkbookBase class. This class redirects all calls to its members to an internal implementation of the Microsoft.Office.Tools.Excel.Workbook interface in the Visual Studio Tools for Office runtime. For more information, see Programming Document-Level Customizations.

NoteNote

This interface is implemented by the Visual Studio Tools for Office runtime. It is not intended to be implemented in your code. For more information, see Visual Studio Tools for Office Runtime Overview.

Usage

This documentation describes the version of this type that is used in Office projects that target the .NET Framework 4 and the .NET Framework 4.5. In projects that target the .NET Framework 3.5, this type might have different members and the code examples provided for this type might not work. For documentation about this type in projects that target the .NET Framework 3.5, see the following reference section in the Visual Studio 2008 documentation: http://go.microsoft.com/fwlink/?LinkId=160658.

Show:
© 2014 Microsoft