Do you know any tutorial for creating MFC ActiveX objects that can be used in JScript or VBScript (Windows Script Based Host)?
I mean an OCX that can be used as:
var x= new ActiveXObject("name");
and NOT this:
<object id="xxx" classid="CLSID:xxxx">
so far everything that I found just allow using an activex with html tags and they fail to initialize with script engine.
As far as getting started goes, I highly recommend you check out A Beginner Tutorial for Writing Simple COM/ATL DLL and Using it with .NET by ThatsAlok.
I’ve tried a number of different techniques in creating ActiveX objects, and, I found the ATL C++ to be one of my favourites. The key essentials of the tutorial are:
ISimpleCom)SimpleATLcom.SimpleCom)Some things the tutorial doesn’t cover is:
The latter, you already know how to do that, but, for completeness. In JScript, it’s:
And, in VBScript, it’s: