for part of a project that its required to record the voice , i develop this simple program to record system sounds via microphone ,in this program i useThe mciSendString function , it sends a command string to an MCI device. The device that the command is sent to is specified in the command string. you can download source code from below link

Parameters

lpszCommand
Pointer to a null-terminated string that specifies an MCI command string. For a list, see Multimedia Command Strings.

lpszReturnString
Pointer to a buffer that receives return information. If no return information is needed, this parameter can be NULL.

cchReturn
Size, in characters, of the return buffer specified by the lpszReturnString parameter.

hwndCallback
Handle to a callback window if the “notify” flag was specified in the command string.

click here for sound recording vb.net +source code download

این مطلب هم میتواند برای شما مفید باشد   search MySQL database and variable conversion using PHP + source code