using System;
using System.Net;
class MainClass
{
public static void Main()
{
IPAddress test1 = IPAddress.Parse("192.168.1.1");
IPEndPoint ie = new IPEndPoint(test1, 8000);
ie.Port = 80;
Console.WriteLine("The changed IPEndPoint value is: {0}", ie.ToString());
}
}
The changed IPEndPoint value is: 192.168.1.1:80