AdoDotNetConnectionSupport.ConnectionTimeout Property

Retrieves or sets the amount of time, in seconds, to wait to establish a connection before terminating the attempt and generating a timeout error.

Namespace:  Microsoft.VisualStudio.Data.AdoDotNet
Assembly:  Microsoft.VisualStudio.Data (in Microsoft.VisualStudio.Data.dll)

Syntax

'宣言
Public Overrides Property ConnectionTimeout As Integer
'使用
Dim instance As AdoDotNetConnectionSupport
Dim value As Integer

value = instance.ConnectionTimeout

instance.ConnectionTimeout = value
public override int ConnectionTimeout { get; set; }
public:
virtual property int ConnectionTimeout {
    int get () override;
    void set (int value) override;
}
public override function get ConnectionTimeout () : int
public override function set ConnectionTimeout (value : int)

Property Value

Type: System.Int32

Returns an integer representation of the allowable timeout period, in seconds.

Exceptions

Exception Condition
NotSupportedException

The provider does not support connection timeout.

Remarks

The default value depends on the data provider. A value of zero indicates there is no timeout, meaning the data provider will wait indefinitely, or until something other than the data provider causes it to timeout, as with a TCP/IP timeout. The value -1 indicates that timeouts are not supported by the provider.

If timeouts are not supported by the provider, a NotSupportedException should be thrown when trying to set it.

Permissions

See Also

Reference

AdoDotNetConnectionSupport Class

AdoDotNetConnectionSupport Members

Microsoft.VisualStudio.Data.AdoDotNet Namespace