Beispiel #1
0
        private void start()
        {
            listenerChat = new TcpListener(2019);
            listenerChat.Start();

            clientChat = listenerChat.AcceptTcpClient();

            sw = new StreamWriter(clientChat.GetStream(), ASCIIEncoding.ASCII);
            StreamReader sr = new StreamReader(clientChat.GetStream(), ASCIIEncoding.ASCII);

            ChatClass cclass = new ChatClass(outputBox, clientChat);

            chatThread = new Thread(cclass.run);
            chatThread.Start();
        }
Beispiel #2
0
        private void start()
        {
            listenerChat = new TcpListener(2019);
            listenerChat.Start();

            clientChat = listenerChat.AcceptTcpClient();

            sw = new StreamWriter(clientChat.GetStream(), ASCIIEncoding.ASCII);
            StreamReader sr = new StreamReader(clientChat.GetStream(), ASCIIEncoding.ASCII);

            ChatClass cclass = new ChatClass(outputBox, clientChat);
            chatThread = new Thread(cclass.run);
            chatThread.Start();


        }