Skip to Content
0
Nov 24, 2008 at 11:00 AM

filtering a inner node of a hierarchy with SetFilterValue does not work

55 Views

Hello,

i have a macro which filters a node from the hierarchy (ZCS_RDRUN = Reporting Unit). This node due to SAPNote 417601 can be a leaf node or a inner node. I have the following code

...

Dim value_runit As String

'Variables deklaration for BEX

'BEX Objects

Dim dp As Object 'Data Provider

Dim dimension As Object 'Reporting Unit Dimension

Dim filters As Object 'BEx Filter Object

Set dp = BEx.DataProviders.Item("DP_1")

Set dimension = dp.Request.Dimensions.Item("ZCS_RDRUN")

Set filters = dimension.filters

...

Call filters.SetFilterValue(value_runit) ' --> value_runit can be single leaf or hierarchy node

Call BEx.FrontendUpdate

Call BEx.Render

For single leafs the italic written row is setting the filter and displaying the correct results but when we have a inner node it is also setting the filter but does not display the result of the inner node, unfortunately the result of the corresponding single leaf is shown.

I also tried it with the command Run "SAPBEX.xla!SAPBEXsetFilterValue", value_runit, "ZCS_RDRUN") instead of using the Call filters.SetFilterValue(value_runit)-row

Unfortunately it is not showing the values of the hierarcical inner node. Which command is the right one and how can i use it to display the result of the inner node calculated as the aggregate of the node's children? Could anyone help me out with this?