如果存在专门为多维数据集字段显示的成员属性,则返回 True。Boolean 类型,只读。
expression.HasMemberProperties
expression 必需。该表达式返回一个 CubeField 对象。
本示例确定是否存在专门为多维数据集字段显示的成员属性,并通知用户。本示例假定数据透视表位于活动工作表上。
Sub UseHasMemberProperties()
    Dim pvtTable As PivotTable
    Dim cbeField As CubeField
    Set pvtTable = ActiveSheet.PivotTables(1)
    Set cbeField = pvtTable.CubeFields("[Country]")
    ' Determine if there are member properties to be displayed.
    If cbeField.HasMemberProperties = True Then
        MsgBox "There are member properties to be displayed."
    Else
        MsgBox "There are no member properties to be displayed."
    End If
End Sub