指定された各メンバーの属性情報を戻します。
構文
EsbCheckAttributes
(
hCtx
,
Count
,
AttrNameArray()
,
AttrTypeArray
)
ByVal
hCtx
As Long
ByVal
Count
As Integer
AttrNameArray()
As String
AttrTypeArray
As Variant
| パラメータ | 説明 |
|---|---|
hCtx |
コンテキスト・ハンドル |
Count |
指定した次元およびメンバーの数 |
AttrNameArray() |
指定した次元およびメンバーの名前の配列 |
AttrTypeArray |
属性のタイプの配列に対する、次の定数識別子のいずれかになります:
|
備考
入力対象の名前のカウントおよびメンバー名のリストを予期します。
単一のメンバー名またはメンバー名の配列を受け入れ、属性のタイプの情報を入力した各メンバーに戻します。
メンバー名は、属性次元名か属性メンバー名と、基本次元名か基本メンバー名のいずれかの組合せになります。
戻り値
正常終了の場合はsts = 0が戻され、AttrTypeArray()の値が入力されます。無効なメンバー名が渡された場合は、エラーが戻されます。
アクセス
この関数を使用するのに、特別な権限は必要ありません。
例
' NOTE: 'Out' is a sub to print the output within quotes to a listbox or text box.
Sub ESB_CheckAttributes()
Dim hCtx as long
Dim sts as long
Dim MbrNameArr() As String
Dim AttrTypeArr As Variant
Dim Count As Integer
Dim index As Integer
Dim test As Integer
Count = InputBox("Enter the number of attribute members")
ReDim MbrNameArr(Count)
For index = 0 To Count - 1
MbrNameArr(index) = InputBox("Enter attribute member name")
Next index
sts = EsbCheckAttributes(hCtx, Count, MbrNameArr, AttrTypeArr)
If sts = 0 Then
For index = LBound(AttrTypeArr) To UBound(AttrTypeArr)
test = AttrTypeArr(index)
Select Case test
Case ESB_STANDARD_MEMBER
Out MbrNameArr(index) & " is of type ESB_STANDARD_MEMBER"
Case ESB_STANDARD_DIMENSION
Out MbrNameArr(index) & " is of type ESB_STANDARD_DIMENSION"
Case ESB_BASE_MEMBER
Out MbrNameArr(index) & " is of type ESB_BASE_MEMBER"
Case ESB_BASE_DIMENSION
Out MbrNameArr(index) & " is of type ESB_BASE_DIMENSION"
Case ESB_ATTRIBUTE_MEMBER
Out MbrNameArr(index) & " is of type ESB_ATTRIBUTE_MEMBER"
Case ESB_ATTRIBUTE_DIMENSION
Out MbrNameArr(index) & " is of type ESB_ATTRIBUTE_DIMENSION"
Case ESB_ATTRIBUTED_MEMBER
Out MbrNameArr(index) & " is of type ESB_ATTRIBUTED_MEMBER"
Case Else
Out MbrNameArr(index) & " is of INVALID Type or Invalid Member Name "
End Select
Next index
Else
Out "EsbCheckAttributes failed:" & sts: Exit Sub
End If
End Sub
関連トピック