Hi i tried the example which was mentioned in msdn site (http://msdn.microsoft.com/en-us/library/ms733069.aspx) I was successful in hosting the service in windows service. Later I tried to consume it creating a WCF client and was not able to create client code using Svcutil.exe . I tried the other way by creating a console app as client and tried giving the service as ref. But it failed saying :
There was an error downloading ‘http://localhost:8001/ServiceModelSamples/service’. Unable to connect to the remote server No connection could be made because the target machine actively refused it 127.0.0.1:8001 Metadata contains a reference that cannot be resolved: ‘http://localhost:8001/ServiceModelSamples/service’. There was no endpoint listening at http://localhost:8001/ServiceModelSamples/service that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details. Unable to connect to the remote server No connection could be made because the target machine actively refused it 127.0.0.1:8001 If the service is defined in the current solution, try building the solution and adding the service reference again.
Can you help me in going further?? I am stuck here.