Winamp published a list of codes to control the program using
SendMessage().  The web page is listed in my code below.

I can get the set of WM_COMMAND codes to work (stop and play), but not the
WM_USERS codes (mute and status.  I have no way of knowing if the problem
is caused by my code, Win32::GUI, or Winamp.  I'd appreciate it if any
Winamp users could take a quick look at this.

Thanks!
Todd


use Win32::GUI;

#Win32::GUI home: http://dada.perl.it/
#Win32::GUI docs: http://dada.perl.it/gui_docs/Win32_GUI.html#Version
#Winamp docs: http://www.winamp.com/nsdn/winamp2x/dev/sdk/api.jhtml

$winampHandle = Win32::GUI::FindWindow("Winamp v1.x", "");
print "Handle: $winampHandle\n";

## STATUS ##
#print Win32::GUI::PostMessage( $winampHandle, WM_USER, 101, 0 );
#print Win32::GUI::PostMessage( $winampHandle, WM_USER, 0, 101 );

## MUTE ##
#Win32::GUI::SendMessage( $winampHandle, WM_USER, 122, 0 );
#Win32::GUI::SendMessage( $winampHandle, WM_USER, 0, 122 );

## PLAY ##
#Win32::GUI::SendMessage( $winampHandle, WM_COMMAND, 40045, 0 );

## STOP ##
#Win32::GUI::SendMessage( $winampHandle, WM_COMMAND, 40047, 0 );


Reply via email to