WCF Self Hosting & Finding configured endpoings throug console application

Kotra.Ramakrishna
Posted by Kotra.Ramakrishna under WCF category on | Points: 40 | Views : 3176
Self Hosting WCF Application in console app

ServiceHost host = new ServiceHost(typeof(UserDetails));
host.Open();
Console.WriteLine("Service is running...");


Showing Configured Endpoints

            foreach (ServiceEndpoint se in host.Description.Endpoints)
Console.WriteLine(se.Address.ToString());

Console.ReadLine();

Comments or Responses

Login to post response