Client & Server using TcpClient
Hi everyone...
I am working with a windows application using C#.net for Client & Server.
Client prg will send the information & Server prg will listen the information.
In Server program I wrote the below code:
TcpListener tcpListener = new TcpListener(8001);
tcpListener.Start();
Socket socketForClient = tcpListener.AcceptSocket();
if (socketForClient.Connected)
{
//My Code
}
In Client program I wrote the below code:
TcpClient tcpclnt = new TcpClient();
tcpclnt.Connect(127.0.0.1,8001);
{
//My Code
}
The above code is working fine, the problem is i need to run this client exe from server. So every client machine must have dotnet framework which is not possible in my case. Is there any optional to do the client program alone in some other way like (vbs,javascript,c,web application)
I have tried in vbs some thing like this
Set wsck0 =CreateObject("MSWinSock.Winsock")
but this too need the MSWinSock.OCX in every client machine....
can anyone???
__________________
Cheers
Sankar
|