Welcome to HBH! If you have tried to register and didn't get a verification email, please using the following link to resend the verification email.
VB
if the code is entirly correct, and both the client and the server are running. then instantly really
are you using SIN connection or Direct?
heres an example of direct connection
client:
Private Sub cmdconnect_Click()
On Error Resume Next
Winsock1.Connect "127.0.0.1", "6080"
End Sub
server:
Private Sub Form_Load()
Timer1.Interval = "1000"
Timer1.Enabled = True
Winsock1.Close
Winsock1.LocalPort = "6080"
Winsock1.Listen
End Sub
Private Sub Timer1_Timer()
If Winsock1.State <> 7 Then
Winsock1.Close
Winsock1.Listen
Else
Exit Sub
End If
End Sub
Private Sub Winsock1_ConnectionRequest(ByVal requestID As Long)
Winsock1.Close
Winsock1.Accept requestID
End Sub
Private Sub Winsock1_Error(ByVal Number As Integer, Description As String, ByVal Scode As Long, ByVal Source As String, ByVal HelpFile As String, ByVal HelpContext As Long, CancelDisplay As Boolean)
Winsock1.Close
Winsock1.Listen
End Sub
works for me, you should learn how to split data then u shuld b able to make a wikid program
Here is all the connection stuff
Server:
Form
Winsock1.LocalPort = 80
Winsock1.Listen
End Sub
Private Sub Winsock1_ConnectionRequest(ByVal requestID As Long)
On Error Resume Next
If Winsock1.State <> sckClosed Then Winsock1.Close
Winsock1.Accept requestID ```
Client:
```markup
Private Sub Label2_Click()
Winsock1.Close
Dim host As String
Dim port As String
host = Text1.Text
port = "80"
If host = "" Or host = "This is where you put the Target IP" Then
MsgBox "Please enter a host IP", vbDefaultButton1, "Enter Host"
End If
Winsock1.Connect host, port
End Sub```
I think thats all the connection related stuff. So, ideas?