ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > FARR Plugins and Aliases

Any "easy" way to create ActiveX objects (for use with JScript)?

(1/2) > >>

ewemoa:
I've been looking for an easy way [1] to create ActiveX objects so that FScript JScript plugins can get access to more functionality.  I haven't found a good way yet, but one thing that looks promising is hinted at in the section titled "Creating a COM component" in the following (plus perhaps using something like py2exe or cx_Freeze):

  http://stormcoders.blogspot.com/2005/07/taking-advantage-of-com-with-python.html

I haven't manage to get it working yet (not sure what I'm doing wrong), but I'm wondering if anyone else has tried anything similar or has a better idea.

Any thoughts?


[1] Preferably doable w/ free tools, no nasty license agreements to accept, straight-forward to code, etc.

CWuestefeld:
By far the easiest way to code up ActiveX objects is using Visual Basic v6.

It's also possible to create them using VB.Net (or any .Net language) with Interop, and this could be done with the free Express editions I believe, but if you're going to do that, you may as well just use the .Net library.

ewemoa:
Thanks for the feedback.

A bit wary w.r.t. .NET regarding deployment among other things -- I don't suppose Mono can be used to achieve similar results (although even if possible, may be this approach would also have similar characteristics -- e.g. size)...not turning up anything yet on this.  Perhaps I will keep looking :)

phitsc:
Maybe ecaradec could offer a useful selection of WIN32 functions through the IFARR interface. He did do that in the old FScript plugin (exec and getIniValue).

ecaradec:
Maybe ecaradec could offer a useful selection of WIN32 functions through the IFARR interface. He did do that in the old FScript plugin (exec and getIniValue).

--- End quote ---

I thought to use the lib_ffi (which is a wrapper that allow script language to call native code ) to allow jscript to call any native functions. However this is a bit laborious to bind with active scripting since nobody seem to have done that before. I'm not sure there is that many functions that would be useful.

You also have the FARR.getObject function available that give you access to the wmi objects. You also have sockets in the recent version. You could implement the functionnalities in a server and communicate via sockets. You could also use another script language that come with libraries that allow many more things than the jscript allow.

Navigation

[0] Message Index

[#] Next page

Go to full version