Say i have declare a module for connection and two buttons...
one button has the method connect() and
the other has the method disconnect()....
how do i actually connect after i had disconnect my tcpC...
I could not connect after i disconnect my connection...
ThanksCode:Imports System.Net.Sockets Module Connection Dim tcpC As New TcpClient Public Sub Connect() 'Connect from this to the server at Port 6970 Try tcpC.Connect("152.138.40.200", 6970) Catch e As Exception Console.WriteLine(e.ToString()) End Try End Sub Public Sub Disconnect() tcpC.Close() End Sub End Module




Reply With Quote