views:

762

answers:

4

How can I get notifications about what is the currect active window and when this changes without polling GetActiveWindow or using global hooks?

I don't like polling, and I'm working in C# and global hooks don't work (mostly).

A: 

You can't but you might want to try something someone has already created like this product.

joegtp
A: 

Thanks, but the link you provided is not relevant for creating system-wide hooks.

+1  A: 

I have never found a clean way to get notified. I use GetForegroundWindow with a timer. :(

Martin Plante
A: 

did you get anywork around for getting active window handle without using a timer? I am also trying to digg the same issue but no success yet.

alee