Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: Set volume when playing wave file


This question is not answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 0
Greg Reese

Posts: 100
Registered: 7/15/05
Set volume when playing wave file  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 6, 2015 1:56 PM
On a Windows desktop app, I want to play a WAV file at a volume that my program sets but I'm having a hard time figuring out how. PlaySound() looks very easy to use but as far as I can tell, you can't set the volume with it. The media player (TMediaPlayer in VCL) won't set the volume unless the device type is digital-video or VCR, as documented in the Microsoft help for the MCI_SETAUDIO command.

The app will run on Windows 7 or later. I just need to set the volume before playing the WAV file, not while it's playing.

Thanks.

Greg Reese
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02