Solved

How to mute or set the volume of Flash ActiveX player control in windows application ?

Posted on 2003-10-29
3
1,773 Views
Last Modified: 2007-12-19
I'd like to know how to mute or set the volume of Flash Player when it is embed in my application.

I note that Quicktime can play Flash movies and mute or set the volume of these movies.
I'd like to do the same.

Thanks for your answer.
0
Comment
Question by:noulouk
3 Comments
 
LVL 96

Accepted Solution

by:
Bob Learned earned 50 total points
ID: 9645560
You might get better results if you ask this question in the Flash TA under Web Development/Web Dev. Software.
0
 
LVL 22

Expert Comment

by:_TAD_
ID: 9646324


I'm not sure how to do it in flash in particular, but here is how you can mute the sound of your computer


Here is the WINAPI for the dll you can use if you don't want to go through the hassle of using DIRECTX.

[DllImport("winmm.dll")]
Private static extern long auxSetVolume(long uDeviceID, long dwVolume);

uDeviceID:
The device ID of the auxiliary audio device to set the volume of. Valid values range from zero to the number of auxiliary audio devices minus one.

dwVolume:
The new volume setting of the device. If the device supports separate left and right channel volumes, the low-order word contains the left channel volume and the high-order word contains the right channel volume. If the device supports only one overall volume, the low-order word is the volume. Valid volumes range from 0 to 0xFFFF.



When referencing this as a LONG value, I am pretty sure that they mean this is an Int32 value (which is a standard int primitive type in .NET, where as Int16 is the standard size of the Integer primitive type in most other platforms).  Also something to note is how the volume is controlled.  you may have to do some Hex conversion to get it right.

//sets both the left and right speakers to half volume
retval=auxSetVolume(0,0x80008000);

//sets both the left and right speakers to full volume
retval=auxSetVolume(0,0xFFFFFFFF);

//Mutes both the left and right speakers
retval=auxSetVolume(0,0);

0
 
LVL 28

Expert Comment

by:ciuly
ID: 14953746
Hi noulouk,

did you find a way of setting the volume using the flash activex control? I am searching for wuote some time for this same issue and can't sem to find anything relevant.

Thanks.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

747 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

14 Experts available now in Live!

Get 1:1 Help Now