// Collection of code snippets by Arne Vajhøj // (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) using System; using System.IO; using System.Net.Sockets; class Client { public static void Main(string[] args) { TcpClient client = new TcpClient("localhost", 1234); StreamWriter wrt = new StreamWriter(client.GetStream()); for(int i = 0; i < 100; i++) { wrt.WriteLine("Dette er en test"); } wrt.Close(); client.Close(); } }