InetSendSound2 Example for C++ 5.0 and later

// This example uses LEAD Capture control to capture audio from the microphone and uses the LEAD //Internet Control to send it to a remote computer. For an example of starting and stopping recording
//refer to the LEAD Capture control documentation.

void CNetDlg::OnCapAudioDataLeadcapctrl(const VARIANT FAR& pData, long lBytesRecorded, short iIndex)

{
   // send sound to remote computer (items in SendList property)
   // you should be connected to a remote computer first by using the
   // InetConnect method of the Internet COM

   VARIANT var;
   var = m_LEADCap1.GetCapWaveExtraData(iIndex);

   m_pRasterInet->InetSendSound2(m_LEADCap1.GetCapWaveFormatTag (iIndex), m_LEADCap1.GetCapWaveChannels (iIndex),
m_LEADCap1.GetCapWaveSamplesPerSec (iIndex), m_LEADCap1.GetCapWaveAvgBytesPerSec (iIndex), m_LEADCap1.GetCapWaveBlockAlign (iIndex), m_LEADCap1.GetCapWaveBitsPerSample (iIndex), (short)m_LEADCap1.GetCapWaveExtraSize (iIndex), &var, (VARIANT *)&pData, lBytesRecorded);

   VariantClear(&var);
}