Jump to content

COM component that allows hooking into any window


faisalv
 Share

Recommended Posts

Does anyone know of any COM Automation components that one can use from WSH to hook into a window's message queue or listen to mouse/keyboard events?

What i'd like to write is something roughly like this (pseudo-codish - oh if only autoit allowed this):

var autoit = new ActiveXObject("AutoIt..");

autoit.on("[active]","MOUSE_CLICK", function(x,y) { wscript.echo("clicked at " + x + " " + y + " in active window"); });

Anyone know of any wsh usable component out there that allows anything remotely like this?

I know meadco's scriptx has some nice functionality - but it doesn't allow setting windows hooks (ala SetWindowsHooksEx etc..) via jscript :(

I'd really rather not learn/use any other scripting language to accomplish this (and if such a component does not exist, i would consider writing one using VS - but as you can understand, i'd rather not do this if there are some good solutions already out there ;)

I see on some of the other forums that a hook.dll was developed that allows some useful similar functionality - but I was hoping for something that allows COM automation so that I can use it directly from WSH.

Has anyone else felt the need for anything like this?

thanks in advance,

Faisal Vali

Radiation Oncology, Loyola

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...