Hi, I'm trying to get the current active window (including all other application's windows). I tried with getactivewindow() but it only works with my application. Are there any other ways to notice the focus on other applications too?
Printable View
Hi, I'm trying to get the current active window (including all other application's windows). I tried with getactivewindow() but it only works with my application. Are there any other ways to notice the focus on other applications too?
no surprise you found your program. When it looks for the active window, the program itself IS the active window...
I'm sure, there was another way. I'll look for it
------------------
Razzle
ICQ#: 31429438
What is the difference between a raven?
-The legs. The length is equal, especially the right one. :D
There is no other way. GetActiveWindow returns the hWnd of the active window. And indeed, if you press on a command button to find out the active window, you're app is active.
You can try it out though using a timer, and the GetWindowText API, check every x-seconds what the active window is, get the windowtext and show it in a msgbox or whatever, you'll see that it works....