I'm using a PowerShell script and WinSCP to upload a file onto an SFTP site, Root\Users\SFTPSite
and it's placing the directory onto the SFTP site that I'm uploading from. So instead of putting it on Root\Users\SFTPSite
it's putting it into Root\Users\SFTPSite\Outbound
. Not sure if it's a permissions issue that's preventing me from placing it in the SFTPSite
directory or something to do with how the SFTP site was setup or something else because I'm using the same script for other sites without a problem. Here are the parameters I'm using
param (
$localPath = "\\fileshare\ftp\ThirdParty\Outbound\",
$remotePath = "/users/SFTPSite/"
)
And here is how I'm transferring,
$transferResult = $session.PutFiles($localPath, $remotePath, $False, $transferOptions)
Any help would be greatly appreciated. - Thanks.