Releasing a connection

Top  Previous  Next

To disconnect from the SSH server and cleanup any resources invoke the SshSession.Disconnect method. You should always invoke the SshSession.Disconnect method after you are finished with the SSH session.

 

Example

 

[C#]

 

// disconnect from server

session.Disconnect();

 

[VB]

 

' disconnect from server

session.Disconnect