ashok has asked for the wisdom of the Perl Monks concerning the following question:

Hi, Is there any facility to playback the voice recorded data files in perl on windows? I have stored "yes" in one file and "no" in another file. Based upon the output of one user entry I want to playback the file stored "yes" if the user entry is correct. Otherwise I want to play back "no". Thanks Ashok

Replies are listed 'Best First'.
Re: play back voice recorded files
by Trinary (Pilgrim) on Jan 09, 2001 at 04:53 UTC
    Win32::Sound

    CPAN search. Learn it, live it, love it.

    use Win32::Sound; Win32::Sound::Volume('100%'); if ($correct_answer) { Win32::Sound::Play("yes.wav"); Win32::Sound::Stop; } else { Win32::Sound::Play("no.wav"); Win32::Sound::Stop; }

    Enjoy

    Trinary