共用方式為


ConnectionSettings.PooledConnectionLifetime 屬性

取得或設定共用連接的存留期間。

命名空間:  Microsoft.SqlServer.Management.Common
組件:  Microsoft.SqlServer.ConnectionInfo (在 Microsoft.SqlServer.ConnectionInfo.dll 中)

語法

'宣告
Public Property PooledConnectionLifetime As Integer 
    Get 
    Set
'用途
Dim instance As ConnectionSettings 
Dim value As Integer 

value = instance.PooledConnectionLifetime

instance.PooledConnectionLifetime = value
public int PooledConnectionLifetime { get; set; }
public:
property int PooledConnectionLifetime {
    int get ();
    void set (int value);
}
member PooledConnectionLifetime : int with get, set
function get PooledConnectionLifetime () : int 
function set PooledConnectionLifetime (value : int)

屬性值

型別:Int32
Int32 值,指定共用連接的存留期間 (以秒為單位)。

請參閱

參考

ConnectionSettings 類別

Microsoft.SqlServer.Management.Common 命名空間