Subfunction Problem

Sep 7, 2009 at 7:24 PM


I have a problem working with sub functions. while Expression("Sma([x],20)") works, Expression("Sma(Sma([x],20)-[y]),20)") does not.

It seems that the parse does not parse from inside out for each single function.

Eval Expression(Sma(Sma([1],[2],1),20,1) *2) : Function not found
Parameter name: Sma :    at Evaluant.Calculator.Domain.EvaluationVisitor.Visit(Function function)
   at Evaluant.Calculator.Domain.Function.Accept(LogicalExpressionVisitor visitor)
   at Evaluant.Calculator.Domain.EvaluationVisitor.Visit(BinaryExpression expression)
   at Evaluant.Calculator.Domain.BinaryExpression.Accept(LogicalExpressionVisitor visitor)
   at Evaluant.Calculator.Expression.Evaluate()

But its also possible, that I made some mistakes. In this case I would ask you for a small peace of working code. Of course I could send you mine, but its reaaallly big and not easy to workout what I am doing :-)


Sep 7, 2009 at 10:59 PM

It's ok, I found the issue and published a new release to correct it. Another user sent me teh same issue the same day, couldn't make you wait more.

Sep 8, 2009 at 6:36 AM

sorry, just wrote you after seekeing and probing for hours ;-)

but thank you very much, for doing this quite fast fixes!