I think I have discovered a bug in the CalcQuick class.
Given the following example:
calculator.AutoCalc = true;
calculator.Engine.AddFunction("REUTER", new Syncfusion.Calculate.CalcEngine.LibraryFunction(GetReutersData));
calculator["Bond Turnover 2017"] = "=REUTER('NZSPREAD,IRGROW,3,1,48,5')";
calculator["IIB 2016"] = "=REUTER(\"NZG0216=FISW,HS_CODE\")";
calculator["TEST"] = "=([Bond Turnover 2017] + [IIB 2016])/2";
calculator["TEST1"] = "=REUTER('NZSPREAD,IRGROW,3,1,48,5') + REUTER(\"NZG0216=FISW,HS_CODE\")";
calculator["TEST2"] = "=[TEST]*2";
If I change the value of "Bond Turnover 2017", I would expect CalcQuick to fire one ValueSet event for each dependent expression: "Bond Turnover 2017", "TEST" and "TEST2".
However QuickCalc is firing multiple ValueSet events for the same expression as well as unrelated expressions such as (eg. “IIB 2016”). The first few times I change “Bond Turnover 2017” I get a total of 12 ValueSet events in the following order:
“Bond Turnover 2017”, “Bond Turnover 2017”, “IIB 2016”, “TEST”, “Bond Turnover 2017”, “IIB 2016”, “TEST”, “TEST2”, “Bond Turnover 2017”, “IIB 2016”, “TEST”, “TEST2”.
After several changes to “Bond Turnover 2017” CalcQuick fires ValueSet events recursively.
If this can be fixed so that only one ValueSet event for each dependent expression is fired then I will be able to achieve what I require.