Forum Discussion
AlexKaras
12 years agoCommunity Hero
Hi Daniel,
Eval() does not perform any conversion but takes an input string and passes it to the runtime engine and returns a result. As VBScript is interpreting language, this means that the passed string will be parsed by the runtime engine in the current execution context and executed.
"in the current execution context" means that all components of the string must evaluate to variables, objects, functions, etc. that are available at the point where Eval() is called.
E.g., in order for the
Set obj = Eval("ObjFind(""abcd"", i)")
call to succeed, ObjFind() function must be defined and be accessible, it must return a reference to the object and i variable must be defined.
Eval() does not perform any conversion but takes an input string and passes it to the runtime engine and returns a result. As VBScript is interpreting language, this means that the passed string will be parsed by the runtime engine in the current execution context and executed.
"in the current execution context" means that all components of the string must evaluate to variables, objects, functions, etc. that are available at the point where Eval() is called.
E.g., in order for the
Set obj = Eval("ObjFind(""abcd"", i)")
call to succeed, ObjFind() function must be defined and be accessible, it must return a reference to the object and i variable must be defined.