Qualcuno ha usato i socket con VB.NET?
AIUTATEMI!!!!!!!!!
Stabilisco la connessione con il server
codice:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'inizio la connessione con il server
With AxWinsock1
Call .Close()
.RemoteHost = "127.0.0.1"
.RemotePort = 10101
Call .Connect()
End With
End Sub
Invio dei dati e mi da un errore
codice:
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
dim msg as string
msg="Invio dati"
AxWinsock1.SendData(msg)
End Sub
L'errore dovrebbe essere sul tipo di dati che invio, cosa devo fare per inviare una stringa?
Grazie