any volunteers to convert VB source code below to c#? I really would
appreciate that, because I wouldn't like to learn two new languages...
This function can be found from ExceleTel Inc www-site and is
copyrighted by the corresponding corporation. Unfortunately, they
didn't have c# version from this... Thx in advance!
Source:
-----------
Private Function IsVoiceModem() As Boolean
Dim ModemMediaModes As Integer
Dim VoiceModemMediaModes As Integer
' These are the minimal media modes expected for standard data
modems
ModemMediaModes = LINEMEDIAMODE_INTERACTIVEVOICE +
LINEMEDIAMODE_DATAMODEM
' These are the minimal media modes expected for voice modems
VoiceModemMediaModes = ModemMediaModes + LINEMEDIAMODE_UNKNOWN + _
LINEMEDIAMODE_AUTOMATEDVOICE
' Check to see if the selected device is a modem and it is a voice
modem
If (InStr(1, etLine1.TAPITSP, "Modem", 1) 0) And _
((etLine1.DeviceMediaModesAvailable And VoiceModemMediaModes)
>= _VoiceModemMediaModes) Then
IsVoiceModem = True
Else
IsVoiceModem = False
End If
End Function
Private Sub SetCompletion(ByVal Status As String)
Select Case CurrentPhoneNumber
Case 1
If TextCompletion1.Text = "" Then
TextCompletion1.Text = Status
End If
Case 2
If TextCompletion2.Text = "" Then
TextCompletion2.Text = Status
End If
Case 3
If TextCompletion3.Text = "" Then
TextCompletion3.Text = Status
End If
Case 4
If TextCompletion4.Text = "" Then
TextCompletion4.Text = Status
End If
Case 5
If TextCompletion5.Text = "" Then
TextCompletion5.Text = Status
End If
End Select
End Sub