Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void SSHFileExisting()
- {
- const String host = "212.237.20.10";
- const String username = "root";
- const String password = "T{1*z1#oye";
- const int port = 22;
- using (SftpClient sftp = new SftpClient(host, port, username, password))
- {
- sftp.Connect();
- if (sftp.Exists("/home/photos/5.jpg"))
- {
- textBox1.Text = "Siedzi tam";
- }
- else textBox1.Text = "Ni ma";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement