WebClientProtocol.Timeout Property

Definition

Indicates the time an XML Web service client waits for the reply to a synchronous XML Web service request to arrive (in milliseconds).

C#
public int Timeout { get; set; }
C#
[System.ComponentModel.SettingsBindable(true)]
public int Timeout { get; set; }

Property Value

The time out, in milliseconds, for synchronous calls to the XML Web service. The default is 100000 milliseconds.

Attributes

Examples

The following example sets the Timeout value to 15000 (15 seconds) for the synchronous call to the Add XML Web service method within the Math XML Web service.

C#
math.Timeout = 15000;

Remarks

Setting the Timeout property to Timeout.Infinite indicates that the request does not time out. Even though an XML Web service client can set the Timeout property to not time out, the Web server can still cause the request to time out on the server side.

Applies to

Product Versions
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1

See also