次の方法で共有


Close メソッド

FTP 接続を閉じます。

名前空間:  Microsoft.SqlServer.Dts.Runtime
アセンブリ:  Microsoft.SqlServer.ManagedDTS (Microsoft.SqlServer.ManagedDTS.dll)

構文

'宣言
Public Sub Close
'使用
Dim instance As FtpClientConnection

instance.Close()
public void Close()
public:
void Close()
member Close : unit -> unit 
public function Close()

使用例

次のコード例では、FtpClientConnection が接続であるかどうかを確認します。接続である場合は、Close を使用して接続を閉じます。

// Close the connection to the FTP Server, if it is connected.
if (ftpClientConnection != null)
    ftpClientConnection.Close();
' Close the connection to the FTP Server, if it is connected.
If Not ftpClientConnection Is Nothing Then
    ftpClientConnection.Close()
End If