Returns the description for a cell, given the indexes that identify the cell. GetDescriptionAtIndex also returns the member IDs of the cell’s Account, Intercompany Partner, and Custom dimension members.
<HsvMDDataBuffer>.GetDescriptionAtIndex lCubeIndex, lPeriodIndex, lCellIndex, plAccount, plICP, plCustom1, plCustom2, plCustom3, plCustom4, pbstrDesc
The following example loops through the cells in an HsvMDDataBuffer object and prints each cell’s description to Visual Basic’s Immediate window. The example assumes that the object has previously been filled with data. BeginEnumeration locks the object and returns the number of subcubes in the object. The loops then work as follows:
For each subcube, GetNumPeriodsInCubeForDescriptions gets the number of periods with cells that contain descriptions.
For each period in a subcube, GetNumCellsForDescriptions gets the number of cells that contain descriptions.
For each cell that contains data, GetDescriptionAtIndex gets the description, which is then printed to the Immediate window.
EndEnumeration then unlocks the HsvMDDataBuffer object.
Dim lNumCubes As Long, lNumPers As Long, lNumCells As Long Dim lAccount As Long, lIntCo As Long, lCus1 As Long Dim lCus2 As Long, lCus3 As Long, lCus4 As Long, sDesc As String m_cMDBuffer.BeginEnumeration lNumCubes For i = 0 To lNumCubes - 1 m_cMDBuffer.GetNumPeriodsInCubeForDescriptions i, lNumPers For j = 0 To lNumPers - 1 m_cMDBuffer.GetNumCellsForDescriptions i, j, lNumCells For k = 0 To lNumCells - 1 m_cMDBuffer.GetDescriptionAtIndex i, j, k, lAccount, _ lIntCo, lCus1, lCus2, lCus3, lCus4, sDesc Debug.Print sDesc Next k Next j Next i m_cMDBuffer.EndEnumeration