How to divide using the function Previous()???
How to divide using the function Previous()???
I have two records in my Dataset that are printed in a Databand and I need to divide the last by the first. I am using the bellow expression but there are ocurred errors.
What the format or sintax correct to divide it? I need to divide with two decimal places.
I am using:
{Div(dsMonthAvg.January, Previous(dsMonthAvg, "January"))}
The error thar occured:
c:\Documents and Settings\jair\Configurações locais\Temp\owx9bwz5.0.cs(495,77) : error CS1502: Melhor método sobrecarregado compatível com 'Stimulsoft.Report.Dictionary.StiFunctionsMath.Div(long, long)' tem alguns argumentos inválidos c:\Documents and Settings\jair\Configurações locais\Temp\owx9bwz5.0.cs(495,161) : error CS1503: Argumento '2': não pode converter de 'object' em 'long'.
Thanks for the help.
Jair RC
How to divide using the function Previous()???
Hello Jair,
Try following code:
Thank you.
Try following code:
Code: Select all
{Div(dsMonthAvg.January, (long)Previous(dsMonthAvg, "January"))}
How to divide using the function Previous()???
Hello Jan,
Hello, Jan,
Unfortunately it did not work. No error occurred but did not make the division should do. I found a way to solve the problem, but I believe so I suggested that you should also work. I did like this:
SumD(dsComparativoMensalMedia.GetData ("February", 1)) / SumD(dsComparativoMensalMedia.GetData ("February", 0))
0 is the index of the first record of the Dataset.
1 is the index of the last record of the Dataset.
Thank you.
Jair RC
Hello, Jan,
Unfortunately it did not work. No error occurred but did not make the division should do. I found a way to solve the problem, but I believe so I suggested that you should also work. I did like this:
SumD(dsComparativoMensalMedia.GetData ("February", 1)) / SumD(dsComparativoMensalMedia.GetData ("February", 0))
0 is the index of the first record of the Dataset.
1 is the index of the last record of the Dataset.
Thank you.
Jair RC