Microsoft DirectX 8.1 (Visual Basic)

DirectPlayVoiceTest8.CheckAudioSetup

Runs the Audio Setup Wizard on the specified devices. This wizard runs a series of tests on the devices to determine if they are capable of full duplex audio and to ensure that the microphone is plugged in and working correctly on the capture device.

CheckAudioSetup( _
    guidPlaybackDevice As String, _
    guidCaptureDevice As String, _
    hwndOwner As Long, _
    lFlags As Long) As Long

Parts

guidPlaybackDevice
GUID that identifies the playback device to test. If an empty string is passed for this parameter, Microsoft® DirectPlay® Voice tests the default voice playback device defined by Microsoft® DirectSound® .
guidCaptureDevice
GUID that identifies the capture device to test. If an empty string is passed for this parameter, DirectPlay Voice tests the default voice capture device defined by DirectSound.
hwndOwner
The test wizard invoked by this method is modal. If the calling application has a window that should be the parent window of the wizard, it should pass a handle to that window in this parameter. If the calling application does not have a window, it can pass 0. If the DVFLAGS_QUERYONLY flag is specified, this parameter is not used and the application can pass 0.
lFlags
Flags. The following flags can be set.
DVFLAGS_QUERYONLY
Audio setup is not run. Instead, the method checks the registry to see if the devices have been tested. If the devices have not been tested, the method returns DVERR_RUNSETUP. If the devices have been tested, the method returns DV_FULLDUPLEX if the devices support full duplex audio, or DV_HALFDUPLEX if the devices do not support full duplex audio.
DVFLAGS_ALLOWBACK
Enable the Back button on the Welcome page of the wizard. If the user clicks the Back button on the Welcome page, the wizard exits, and CheckAudioSetup returns DVERR_USERBACK.

Error Codes

If the method fails, Err.Number can be set to one of the following values.

DVERR_INVALIDPARAM
DVERR_RUNSETUP

Remarks

This method contains user interface (UI) elements and raises dialog boxes. If the DVFLAGS_QUERYONLY flag is specified, the tests are not actually run and no UI is raised. Instead the registry is checked to determine the results of a previous test of these devices.