CategoryLocal 属性

       

如果指定名称为自定义函数或命令,返回或设置以用户语言表示名称的类别。String 类型,可读写。

示例

本示例以用户语言显示由 Microsoft Excel 4.0 宏表创建的自定义函数或命令的类别。本示例假定指定的函数名称或命令名称在工作簿中是唯一的。

With ActiveWorkbook.Names(1)
    If .MacroType <> xlNone Then
        MsgBox "The category for this name is " & .CategoryLocal
    Else
        MsgBox "This name does not refer to" & _
            " a custom function or command."
    End If
End With