Waiting period in Webservices

I need to change the timeout period of my web service that was called by a .net console application.

How to change the waiting period.

It is not hosted on IIS. Its the only WSDL. I don't want to write code. I need to change it in app.config

0


source to share


1 answer


Most web services ultimately derive from the WebClientProtocol. This class has a timeout property that can be used to change the timeout. Install it before calling the service and it should do the trick.

Example



void SomeMethod() {
  SomeWebService v1 = new SomeWebService();
  v1.Timeout = 1000;
  v1.AWebServiceCall();
}

      

+2


source







All Articles