VBASigned 属性

       

如果指定工作簿的 Visual Basic for Applications 项目已进行过数字签名,则该值为 TrueBoolean 类型,只读。

示例

本示例加载名为 mybook.xls 的工作簿,然后检测其 Visual Basic for Applications 项目是否已进行数字签名。如果没有进行数字签名,则本示例将显示警告消息。

Workbooks.Open FileName:="c:\My Documents\mybook.xls", _
    ReadOnly:=False
If Workbook.VBASigned = False Then
    MsgBox "Warning! The project " _
    "has not been digitally signed." _
    , vbCritical, "Digital Signature Warning"
End If