Help for TM1RptElLev function

Post Reply
kennyyeung
Posts: 19
Joined: Fri May 15, 2009 12:44 pm
Version: 9.4 MRC
Excel Version: 2000

Help for TM1RptElLev function

Post by kennyyeung »

I am trying to format the active form based on the level of consolidation element. (i.e. a color for each level )
( e.g. level 0 :red, level 2 green & level 3 blue)
I found that TM1RptElLev function could be helpful , but it's lack of example in the developer guide.
Is there any example for reference?
lotsaram
MVP
Posts: 3652
Joined: Fri Mar 13, 2009 11:14 am
OLAP Product: TableManager1
Version: PA 2.0.x
Excel Version: Office 365
Location: Switzerland

Re: Help for TM1RptElLev function

Post by lotsaram »

TM1RPTELLEV is a new function with 9.4 that relates specifically to elements in the subset being used in an active form as opposed to the dimension itself. Specifically this function returns the number of levels between the "root" or top node of the subset and the element being tested.

The result returned is therefore relative to the set of elements in the subset not the whole dimension and it is also kind of the inverse of the TM1 dimension level concept. That is if the subset root is level 5 then a level 4 element would return 1, a level 3 element would return 2, etc.

If you want your formatting in the active form to be absolute with reference to the dimension level of each element then all that is required is to change the formula in the hidden column A to use ELLEV instead (or you could define a formatting attribute and use DBRA). You will also need to change the format look up identifiers in A2:A7 (you can also expand the format range, you are not limited to just 6 formats.)
Post Reply