CLOSESOCKET
Fermeture d'un socket
Declare Function closesocket Lib "wsock32" _
(ByVal sock As Long) As Long
Paramètres :
sock : identifie le socket à fermer
retour : SOCKET_ERROR en cas d'erreur,0 sinon.
Public Const SOCKET_ERROR = -1
Exemple :
Dim Result As Long
Dim sock as long
Result = closesocket(sock)
If Result = SOCKET_ERROR Then
MsgBox "Erreur sur la fermeture du socket"
End If
|