Hi,
Following code does not work. Expected result is 20.
I have one global script and one child script that use it.
numValue variable from the global script is not available from in child script.
Following code does not work. Expected result is 20.
I have one global script and one child script that use it.
numValue variable from the global script is not available from in child script.
using(var globalScript = new VBScriptEngine())
using(var childScript = new VBScriptEngine())
{
Console.WriteLine("Start VBScriptEngine");
globalScript.Script.numValue = 4;
childScript.Script.GlobalScript = globalScript.Script;
Console.WriteLine(childScript.Evaluate("5 * numValue"));
Console.WriteLine("End script");
Console.ReadKey();
}