Debug Jscript, in C# project. Step by Step
* Create a JScript b.js
class myClass
{
var answer : int = 42; // public field
private var pi : double = Math.PI; // private field
static function sayHello() // public method
{
var b = 100;
b= b+1;
return "Hello";
}
}
* build a dll or exe, by VS.Net command
http://msdn.microsoft.com/library/chs/default.asp?url=/library/CHS/jscript7/html/jsoriJScriptCodeWritingCompilingAndDebugging.asp
jsc /debug /target:library b.js
* Create a C# poject. Add reference to Microsoft.JScript and b.dll
* Call class member function defined in b.js.
private void button1_Click(object sender, System.EventArgs e)
{
//myClass b = new myClass();
//b.sayHello();
myClass.sayHello();
}
* Build and debug. step into the function defined in JScript.