C# + IE9 JS Engine Chakra?

隐身守侯 提交于 2019-12-05 15:09:22

[Update] Based on Cheeso's answer it seems you can use IE9's JS engine[/Update]. However I found that V8 JavaScript engine (Chrome's JS engine) mentions that you can use V8 engine in you C++ application. Follow V8 embedder's guide to find out more. I did not find any reference where they mentioned exposing V8 functionality through COM interface, so you might not be able to use it from C#.

Cheeso

Answer to Q#1

Yes, you can interact with Javascript logic running in Chakra from C# via COM.

in Particular, from a c# program, you can startup Chakra via IActiveScript, load some Javascript/ES5 code into it, then invoke methods defined in that Javascript code via a COM IDispatch pointer.

Related:

Answer to Q#2

As far as I know, NO, you cannot install Chakra without installing IE9. You can design your C# app, though, to gracefully degrade to use the existing JScript engine, for computers without Chakra.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!