![]() Ĭreate a new C# Windows based project and put the source code in it. Here we implement an infinite loop in the function getMessage() and call this function in a Thread. The Client program connect to the Chat Server and start a Thread for receive the messages from Server side client. When we start the Chat Client program, we have to enter a User Name for identifying the client in Server side. Here we give " 127.0.0.1 ", because Chat Server and Chat Client are running on the same machine. The Chat Client here is to connect the PORT 8888 of the C# Chat Server in " 127.0.0.1 ". The C# Chat Server Program has two sections. If you don't know the basics of Socket programming, take a look at the section C# Socket Programming before you start this section. ![]() In the previous section C# Multi Threaded Socket Program we saw a C# Multithreaded Server Socket Program communicate with more than one Client at the same time. The C# Chat Client here is a Windows based Application and its main function is to send message to the Chat Server. ![]() NET framework provides two namespaces, System.Net and for managed implementation of Internet protocols that applications can use to send or receive data over the Internet.
0 Comments
Leave a Reply. |