Skip to Content
avatar image
Former Member

BPC VBA- Can I get a list of dimensions by model

Is there a way to get a list of dimensions (not property values) associated with a BPC Model? I want to be able to select a BPC Model (PLAN) and have the system return a list of all dimensions associated with that model. I know how to pull a list of values in a dimension, but I want to be able to pull the list of dimension names. I would like to pull them using VBA, but an EPM function is okay also. Thanks for any help.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Sep 27, 2017 at 08:15 AM

    The VBA function GetDimensionList is documented in EPM help (API).

    Dim epm As New FPMXLClient.EPMAddInAutomation
    
    Public Sub Test()
        Dim strDims() As String
        Dim lngTemp As Long
    
        strDims = epm.GetDimensionList(epm.GetActiveConnection(ThisWorkbook.Worksheets("Sheet1")))
        For lngTemp = 0 To UBound(strDims)
            Debug.Print strDims(lngTemp)
        Next lngTemp
    End Sub

    The model name is defined by connection string. In this sample GetActiveConnection will return the current model connection.

    Add comment
    10|10000 characters needed characters exceeded