Solved

How to Control sound card output using VB

Posted on 1998-09-16
4
243 Views
Last Modified: 2012-05-04
I need to be able to turn my sound card on or off depending on the time of day. I can do the time part of the project but I don't know how to control the operation of the soundcard from VB.??
0
Comment
Question by:rfb
  • 2
4 Comments
 
LVL 1

Expert Comment

by:ryanic
ID: 1435330
If you are using the Sound Card to do playback MIDI and WAVE files only, thne you can use the API function "waveSetVolume" and "midiSetVolume" found in winmm.dll to set the volume to zero. THis should mute out the Sound Card.

I am still searching for a way to control the master volume myself.  Please update me if you found out anything. Thanks.
0
 
LVL 1

Expert Comment

by:ryanic
ID: 1435331
Sorry, but it should be "midiOutSetVolume" and "waveOutSetVolume".

You can also use "mmsystem.dll" for the API call. But the arguments seems to be slightly changes.

0
 
LVL 1

Author Comment

by:rfb
ID: 1435332
sorry...this is audio that is fed into the soundcard from another source. Precisely, I'm feeding a radio into the soundcard and broadcasting it on the Internet using a Real Audio Server. There are certain shows on the Radio that I do Not want to broadcast and I want to automate shutting the audio off and turning it on by writing a VB routine that looks at the time and day and makes the decision to allow the broadcast or not.
0
 

Accepted Solution

by:
stingray earned 100 total points
ID: 1435333
why not try out the control at:

http://www.barint.on.ca/~dcs/dcsMixer/dcsMixer.zip

it allows you to actually set the mute of the sound card or set the master volume.

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now