Control input microphone volume with TrackBar * Locked

Do you need something made? then ask in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
3 posts Page 1 of 1
Contributors
User avatar
tvs praveen
Top Poster
Top Poster
Posts: 205
Joined: Tue Dec 08, 2009 6:20 am

i, I want to know how to control input microphone`s volume with TrackBar
Last edited by tvs praveen on Wed Feb 17, 2010 4:18 am, edited 1 time in total.
User avatar
CodenStuff
Site Admin
Site Admin
Posts: 4392
Joined: Tue Aug 04, 2009 1:47 am

Hello,

In your project make a reference to the attached DLL file and then add a trackbar to your form and use the following code:
Code: Select all
Imports WaveLib.AudioMixer
Place this below "Public Class Form"
Code: Select all
  Dim mMixers As New Mixers
Place this code inside the "Form_Load" event:
Code: Select all
   mMixers.Recording.Lines.GetMixerFirstLineByComponentType(MIXERLINE_COMPONENTTYPE.SRC_MICROPHONE).Selected = True
        TrackBar1.Minimum = 0
        TrackBar1.Maximum = 100
        TrackBar1.Value = 20
Place this in the "TrackBar_Scroll" event:
Code: Select all
           mMixers.Recording.Lines.GetMixerFirstLineByComponentType(MIXERLINE_COMPONENTTYPE.SRC_MICROPHONE).Volume = TrackBar1.Value

I dont know if it works properly because I dont have a microphone at the moment to test it. If it doesnt please wait for someone else to respond.

Download DLL:
WaveLibMixer.zip
Thank you.
You do not have the required permissions to view the files attached to this post.
Welcome to CodenStuff.com Learn Code, Love Code. Thank you for being a member of the community.
User avatar
tvs praveen
Top Poster
Top Poster
Posts: 205
Joined: Tue Dec 08, 2009 6:20 am

Thanks a lot codenstuff wahooo;


Its working well! :D
3 posts Page 1 of 1
Return to “Tutorial Requests”