none
How do I Mute the Microphone in C#

All replies

  • Would you please c heck-out below thread

    http://social.msdn.microsoft.com/Forums/en/csharpgeneral/thread/691a69e5-117e-4072-9041-464d34f5f6c6


    Regards,
    Ahmed Ibrahim
    SQL Server Setup Team
    My Blog
    This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you.
    This can be beneficial to other community members reading the thread.

    Tuesday, July 24, 2012 9:19 PM
  • Would you please c heck-out below thread

    http://social.msdn.microsoft.com/Forums/en/csharpgeneral/thread/691a69e5-117e-4072-9041-464d34f5f6c6


    Regards,
    Ahmed Ibrahim
    SQL Server Setup Team
    My Blog
    This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you.
    This can be beneficial to other community members reading the thread.

    This does not work for me, it requires a 3rd party library, and my app is not allowed to use 3rd party libraries.

    could you please provide a working sample.


    Go Navy


    • Edited by Navy Gunner Tuesday, July 24, 2012 10:08 PM
    Tuesday, July 24, 2012 10:05 PM
  • This is C++ sample

    http://www.codeproject.com/Articles/3094/Audio-Mixer-Functions-Demo

    however you could easily call the API from C# client


    Regards,
    Ahmed Ibrahim
    SQL Server Setup Team
    My Blog
    This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you.
    This can be beneficial to other community members reading the thread.

    Tuesday, July 24, 2012 10:09 PM
  • This is C++ sample

    http://www.codeproject.com/Articles/3094/Audio-Mixer-Functions-Demo

    however you could easily call the API from C# client


    Regards,
    Ahmed Ibrahim
    SQL Server Setup Team
    My Blog
    This posting is provided "AS IS" with no warranties, and confers no rights. Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you.
    This can be beneficial to other community members reading the thread.

    I need it in Native C#, and not some 3rd Party dll, If you don't know how to do this, please pass it on to someone who doe's

    This is not an answer.......


    Go Navy


    • Edited by Navy Gunner Tuesday, July 24, 2012 11:57 PM
    Tuesday, July 24, 2012 11:56 PM
  • I think you can refer to this source code (it's in C though, so you have to learn how to translate it to C# through P/Invoke.).

    The code contains function to set mute to WAVEIN (the MCI object name for microphone). It only refers to MCI library which is a native part of Windows since Win3.X.

    Also note that if you have to support x64 (if your code always compiles with target set to x86, you have no concern on this one), some of the structs have been changed. See this for example and some reference. I'd advise that you check signiture for each struct you used to make sure.

    P.S.: I think I've provided enough hint for you to solve the question. And don't always expect people to spoonfeed you.

    • Edited by cheong00 Wednesday, July 25, 2012 3:36 AM
    Wednesday, July 25, 2012 1:56 AM
  • I think you can refer to this source code (it's in C though, so you have to learn how to translate it to C# through P/Invoke.).

    The code contains function to set mute to WAVEIN (the MCI object name for microphone). It only refers to MCI library which is a native part of Windows since Win3.X.

    Also note that if you have to support x64 (if your code always compiles with target set to x86, you have no concern on this one), some of the structs have been changed. See this for example and some reference. I'd advise that you check signiture for each struct you used to make sure.

    If you can't answer the question, please don't.

    I need a NATIVE C# example.

    Thanks


    Go Navy

    Wednesday, July 25, 2012 2:18 AM
  • Note that the third link in my post contains updated version of the link you quoted.
    Wednesday, July 25, 2012 5:39 AM
  • Note that the third link in my post contains updated version of the link you quoted.

    "This library is part of my Audio library to control Wave Audio "

    foreach(MixerDetail mixerDetail in mMixers.Recording.Devices)
    {
        ...
        ...
    }

    This is from a 3rd Party Library, I need a sample of how to mute the Microphone in Native C#!!!!

    If you can't anwer the question, then don't, quit trying to make it like you are doing something.

    I have already found those links and that is why I am here.


    Go Navy

    Thursday, July 26, 2012 2:38 PM
  • Hi Navy,

    I will try to involve some senior engineers to check this issue. 

    Good day!


    Michael Sun [MSFT]
    MSDN Community Support | Feedback to us

    Monday, July 30, 2012 2:36 AM