[Help] Synchronous Sockets
In C#, I've been trying to use Synchronous Sockets... But when I try and send Data through the Socket, It gives me the error that saids the Server hasn't been connected yet...
my class
Code:
public static void Connection()
{
TcpListener l = new TcpListener(IPAddress.Any, 8484);
l.Start();
running = true;
try
{
l.Server.Send(new Byte[] { 0x10 });
}
catch (SocketException se)
{
Logger.Error(se);
}
while (running)
{
}
Thread.Sleep(1);
}
Re: [Help] Synchronous Sockets
Is this all there is to your Server-side programming? If so, Connection has to be called through the Main method.
Re: [Help] Synchronous Sockets
Re: [Help] Synchronous Sockets
Where are you trying to send that data to? You've made a listen socket, but there's no connected socket.
Re: [Help] Synchronous Sockets
yeah i did
---------- Post added at 05:00 PM ---------- Previous post was at 04:59 PM ----------
yea i did
---------- Post added at 05:07 PM ---------- Previous post was at 05:00 PM ----------
well can somebody make an example how to send data and recieve data through a synchronous socket?