La Biode
Messages postés133Date d'inscriptionjeudi 5 août 2004StatutMembreDernière intervention11 août 2010
-
30 mars 2006 à 19:47
La Biode
Messages postés133Date d'inscriptionjeudi 5 août 2004StatutMembreDernière intervention11 août 2010
-
31 mars 2006 à 19:00
Salut voila j'ai un problème avec la fonction winsock sous vb6, lors de la reception d'un fichier j'ai une erreur comme quoi "le nom ou le numéro du fichier est incorrect". Voila mon code :
Private Sub Winsock_DataArrival(ByVal bytesTotal As Long)
Dim Data As String
Winsock.GetData Data
If Left(Data, 6) = "Taille" Then
clentotal = Int(Mid(Data, 7))
Winsock.SendData "Go"
Exit Sub
End If
If clentotal = "" Then
clentotal = "116000"
End If
If FileOpen <> False Then
Open "C:\VB6FR.DLL" For Binary Access Write As #1
FileOpen = True
ElseIf FileOpen = True Then
DoEvents
End If
cAvance = cAvance + Len(Data)
lblStatut.Caption = Int(cAvance / clentotal * 100) & "%"
If Data = "FinEnvoi" Then
Close #1
FileOpen = False
Winsock.Close
Else
Put 1, , Data L'erreur se trouve ici
End If
End Sub
Voila si vous savez comment on peut déboguer ^^.
ET si vous ne comprennez pas mon problème posez moi des questions j'essayerai d'etre plus précis.
MErci, La Biode.