Welcome to the forum.
I haven't used this in years, and don't intend to revisit it, so you're on your own:
' 1. Download MSCOMM32.OCX to WINDOWS/System32 folder
' 2. From a command line,
' > regsvr32 c:\windows\system32\mscomm32.ocx
' 3. Add a reference to Microsoft Comm Control
Declare Function tapiRequestMakeCall _
Lib "tapi32.dll" _
(ByVal stNumber As String, ByVal stDummy1 As String, _
ByVal stDummy2 As String, ByVal stDummy3 As String) As Long
Sub Test()
DialNumber ("9725551212")
End Sub
Sub DialNumber(sPhoneNumber As String)
If MsgBox("Pick up the phone and click OK to dial " & sPhoneNumber, _
vbInformation + vbOKCancel, "Dial Number") = vbOK Then
If tapiRequestMakeCall(sPhoneNumber, "", "", "") < 0 Then
MsgBox "Unable to dial", vbCritical, "Error!"
End If
End If
End Sub
Bookmarks