Search found 4 matches

by Amorau
Thu Feb 15, 2018 9:16 am
Forum: IBM TM1, Planning Analytics, PAx and PAW
Topic: Evaluation of DBRW Formula in VBA
Replies: 7
Views: 606

Re: Evaluation of DBRW Formula in VBA

Thank you, jrizk,
That was helpful!

Using the Evaluate Method helped:

TM1VBAString = FType & "(" & Chr(34) & Join(argsArrayValue, Chr(34) & "," & Chr(34)) & Chr(34) & ")"
TM1Result = Application.Evaluate(TM1VBAString)

Just using the JOIN instead of For...next.
by Amorau
Wed Feb 14, 2018 3:47 pm
Forum: IBM TM1, Planning Analytics, PAx and PAW
Topic: Evaluation of DBRW Formula in VBA
Replies: 7
Views: 606

Re: Evaluation of DBRW Formula in VBA

Hi Wim, I already split the formula into pieces (with the help of code from the addin) and now I have an array (see below) with all arguments. However the array lengh can be varying, depending on the number of dimension in the queried cube. I found a solution for my problem today: With a "select cas...
by Amorau
Wed Feb 14, 2018 8:02 am
Forum: IBM TM1, Planning Analytics, PAx and PAW
Topic: Evaluation of DBRW Formula in VBA
Replies: 7
Views: 606

Re: Evaluation of DBRW Formula in VBA

Like most of the TM1 functions you can use Application.Run("DBRW" , Arg1 , Arg2, etc) Steve, thanks for your help with this. That was exactly what I had tried unsuccessfully. However your post helped me understanding that my mistake was somewhere else: I had tried: TM1Result = Application.Run(FType...
by Amorau
Tue Feb 13, 2018 3:10 pm
Forum: IBM TM1, Planning Analytics, PAx and PAW
Topic: Evaluation of DBRW Formula in VBA
Replies: 7
Views: 606

Evaluation of DBRW Formula in VBA

Dear Experts, I’m currently working on some automation functions for TM1 in Excel/VBA. For some purpose I would like to pass on the result of a DBRW Formula to a VBA variable. I cannot simply us the cell value, as the DBRW Formula could be part of another calculation within that cell. Example: =DBRW...