Quantcast
Channel: ClearScript
Viewing all articles
Browse latest Browse all 2297

New Post: Parent-child script relation

$
0
0
Hello ifle,

Since you're exposing the parent's global object in the child under the name "GlobalScript", you probably meant to write this:
Console.WriteLine(childScript.Evaluate("5 * GlobalScript.numValue"));
By the way, we don't recommend exposing script items to other script engines. It may work, but it isn't well tested and there are scenarios that are known to be problematic, especially when different script engine classes are involved.

Cheers!

Viewing all articles
Browse latest Browse all 2297

Latest Images

Trending Articles





Latest Images