I would like to know how to give focus(Higlight) Nulsoft's Winamp window with its ever changing caption...
Any Help?
Andy
Printable View
I would like to know how to give focus(Higlight) Nulsoft's Winamp window with its ever changing caption...
Any Help?
Andy
If WinAmp is in background (not Minimized) you can use this:
Winamp v1.x is a class name for WinAmp Window. You may have to check it to make sure (use Spy++ to do it)Code:Private Declare Function BringWindowToTop Lib "user32.dll" (ByVal hwnd As Long) As Long
Private Declare Function FindWindow Lib "user32.dll" Alias "FindWindowA" (ByVal lpClassName As Any, ByVal lpWindowName As Any) As Long
Private Sub Command1_Click()
Dim hwnd As Long
hwnd = FindWindow("Winamp v1.x", CLng(0))
BringWindowToTop hwnd
End Sub
If winamp is miniminized then you can use ShowWindow API to maximize it.
HTH
------------------
Visual Basic Programmer
------------------
PolComSoft
You will hear a lot about it.
[This message has been edited by QWERTY (edited 02-20-2000).]