ReleaseConnections メソッド
AcquireConnections の間に確立された接続を解放します。デザイン時および実行時に呼び出されます。
名前空間: Microsoft.SqlServer.Dts.Pipeline
アセンブリ: Microsoft.SqlServer.PipelineHost (Microsoft.SqlServer.PipelineHost.dll)
構文
'宣言
Public Overridable Sub ReleaseConnections
'使用
Dim instance As PipelineComponent
instance.ReleaseConnections()
public virtual void ReleaseConnections()
public:
virtual void ReleaseConnections()
abstract ReleaseConnections : unit -> unit
override ReleaseConnections : unit -> unit
public function ReleaseConnections()
使用例
private System.Data.OleDb.OleDbConnection oledbConnection;
public override void ReleaseConnections()
{
if (oledbConnection != null && oledbConnection.State != ConnectionState.Closed )
oledbConnection.Close();
}
Private oledbConnection As System.Data.OleDb.OleDbConnection
Public Overrides Sub ReleaseConnections()
If Not (oledbConnection Is Nothing) AndAlso Not (oledbConnection.State = ConnectionState.Closed) Then
oledbConnection.Close
End If
End Sub