You can control the behaviour of the CONSOLE window yourself, unless the package you are using is launching things, but anyway, here's what I use:
use Win32::GUI; my $perlwin = Win32::GUI::GetPerlWindow(); # the console window perl is running in. Win32::GUI::Show( $perlwin, 0 ); # SW_HIDE Win32::GUI::Show( $perlwin, 1 ); # SW_SHOWNORMAL Win32::GUI::Show( $perlwin, 5 ); # SW_SHOW Win32::GUI::Show( $perlwin, 6 ); # SW_MINIMIZE Try your options on these. If something else is firing off this, then you need to get that window, eg, winamp, via GetForegroundWindow(); Play around a little on it. I sometimes use the "owner" window as the "DesktopWindow" to get better results. [EMAIL PROTECTED] -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jon Bjornstad Sent: Friday, May 16, 2008 3:20 PM To: perl-win32-users@listserv.ActiveState.com Subject: Re: controlling Winamp Greetings, I have a Win32 Perl/Tk application that controls Winamp in two different ways. One is via Win32::GUI: $winampHandle = Win32::GUI::FindWindow("Winamp v1.x", ""); Win32::GUI::SendMessage( $winampHandle, WM_COMMAND, 40047, 0 ); 40047 means "Stop". As far as I can determine the above technique cannot be used to load a series of mp3 files into Winamp's playlist. To do this I found an application called 'CLAmp' which somehow takes command line arguments and sends them to WinAmp: > CLAmp.exe /clear /load song.mp3 /load sonata.mp3 /play This does work but a weakness is that a black DOS window flashes in front of my beautiful Perl/Tk app while the loading takes place. I have sent an inquiry to the author of CLAmp to see how it does this loading of mp3 files but thought I would direct my query to this perl-win32-users list as well. Any help is most appreciated. Thank you, Jon _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs