Bonjour,
j'utilise mscomm pour appeler des numéros compris dans une fiche excel. Ca, ça fonctionne. En revanche, une fois la ligne décroché, je dois envoyer d'autre dtmf. Et là, dès la premiere série, mon modem bip (presque comme une tonalité occupé, mais je suis toujours en ligne) puis la ligne fini par couper.

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
DialString = "ATDT" + dialnumber + ";" + vbCr
 
' Communications port settings.
With MSComm1
    .Handshaking = 2 - comRTS
    .RThreshold = 1
    .RTSEnable = True
    .Settings = "9600,N,8,1"
    .SThreshold = 1
    .CommPort = 3
    .InputLen = 0
End With
 
 
RingCount = 0
 
On Error Resume Next
    ' Ouvrir le port s'il est fermé
    If (MSComm1.PortOpen = False) Then
        MSComm1.PortOpen = True
    End If
 
 
    If Err Then
        MsgBox "COM" & comPort & " n'est pas disponible. Changer la propriété à un autre port."
        Exit Sub
    End If
 
' Flush the input buffer.
MSComm1.InBufferCount = 0
 
' Dial the number.
        Application.StatusBar = "Appel en cours du " & dialnumber & " § " & "Transmetteur : " & prom & " § " & Now
        MSComm1.Output = DialString
 
         ' Mode programmation
        If Application.Wait(Now + TimeValue("0:00:20")) Then
        Application.StatusBar = "Transmetteur :" & prom & " - " & " Programmation" & " § " & Now
         MSComm1.Output = "ATDT *#*" + Chr(13)
        End If
 
 
         ' Raccrocher
' Disconnect the modem.
MSComm1.Output = "ATH" + vbCr
 
' Close the port.
MSComm1.PortOpen = False
End Sub
J'ai du mal à trouver d'où viens le problème car MSComm1 n'est pas un truc très documenté...mis à part le tuto de Grafikm sur developpez.