Perhaps use a scripting library - IronPython (python), cs-script (c#) or even MSScriptControl (VBscript) - you can then pass your string expression to the library for evaluation.
Example using MSScript Control:
using MSScriptControl;
...
ScriptControl ScriptEngine = new ScriptControlClass();
ScriptEngine.Language = "VBScript";
string expr = "10+20+30";
object result = ScriptEngine.Eval(expr);
decimal d = Convert.ToDecimal(result);