次の方法で共有


Application.ProtectedViewWindowOpen Event (Excel)

Occurs when a workbook is opened in a Protected View window.

Version Information

Version Added: Excel 2010

Syntax

expression .ProtectedViewWindowOpen(Pvw, )

expression A variable that represents an Application object.

Parameters

Name

Required/Optional

Data Type

Description

Pvw

Required

ProtectedViewWindow

An object that represents the Protected View window that is opened.

Return Value

Nothing

Example

The following code example informs the user that the workbook will be opened in a Protected View window. This code must be placed in a class module and an instance of that class must be correctly initialized. For more information about how to use event procedures with the Application object, see Using Events with the Application Object.

Private Sub App_ProtectedViewWindowOpen(ByVal Pvw As ProtectedViewWindow) 
 MsgBox "You are opening the following workbook in Protected View: " _ 
 & Pvw.Caption 
End Sub 

See Also

Concepts

Application Object Members

Application Object