如果应用程序窗口是“受保护的视图”窗口,则为 True。 此为只读属性。
语法
expression。 IsSandboxed
表达 返回“Global”对象的表达式。
示例
下面的代码示例显示 文档 引用的文档是否位于“受保护的视图”窗口中。
If doc.Application.IsSandboxed Then
MsgBox "The document " & _
"""" & doc.Name & """" & _
" is in a Protected View window."
Else
MsgBox "The document " & _
"""" & doc.Name & """" & _
" is not in a Protected View window."
End If
另请参阅
支持和反馈
有关于 Office VBA 或本文档的疑问或反馈? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。