Click or drag to resize

SftpClientRenameFile(String, String) Method

Renames remote file from old path to new path.

Namespace: Crestron.SimplSharp.Ssh
Assembly: SimplSharpHelperInterface (in SimplSharpHelperInterface.dll) Version: 2.21.121
Syntax
C#
public void RenameFile(
	string oldPath,
	string newPath
)

Parameters

oldPath  String
Path to the old file location.
newPath  String
Path to the new file location.
Exceptions
ExceptionCondition
ArgumentNullExceptionoldPath is null.

-or-

or newPath is null.
SshConnectionExceptionClient is not connected.
SftpPermissionDeniedExceptionPermission to rename the file was denied by the remote host.

-or-

A SSH command was denied by the server.
SshExceptionA SSH error where Message is the message from the remote host.

Version Information

.NET

Supported in: 6.0

.NET Compact Framework

Supported in: 3.5
See Also