Questions tagged [winscp-net]

The WinSCP .NET assembly (winscpnet.dll) is a .NET wrapper around WinSCP's scripting interface that allows your code to connect to a remote machine and manipulate remote files over SFTP, FTP, WebDAV and SCP sessions from .NET languages, such as C#, VB.NET, and others, or from environments supporting .NET, such as PowerShell and SQL Server Integration Services (SSIS).

The WinSCP .NET assembly winscpnet.dll is a .NET wrapper around WinSCP's scripting interface that allows your code to connect to a remote machine and manipulate remote files over SFTP, FTP, WebDAV and SCP sessions from .NET languages, such as C#, VB.NET, and others, or from environments supporting .NET, such as PowerShell and SQL Server Integration Services (SSIS).

For details see:

The assembly is also exposed to COM, and as such it can be used from variety of other programming languages and development environments--e.g., WSH-hosted active scripting languages like JScript and VBScript, Visual Basic for Applications (VBA), Perl, and Python.

For details see:

The library is primarily intended for advanced automation tasks that require conditional processing, loops or other control structures for which the basic scripting interface is too limited. The library is not a general purpose file transfer library. It particularly lacks support for interactive processing and as such it is not well suited for use in GUI applications.

Use tag for all WinSCP related questions, along with .

339 questions
0
votes
1 answer

C# upload file from Windows through WinSCP/SSH tunnel

I use WinSCP desktop application on Windows server for a physical interface to upload files to a Linux server. I use SCP protocol, and in Advanced options I pass a SSH command ssh username@ipaddress on connection to security server to tunnel to the…
0
votes
1 answer

SSIS Script task: FireError() hangs in Catch block

Using SQL Server 2014. I have a script task, that downloads files via WinSCPnet.dll assembly, where I am attempting to log errors to the SSIS log via a FireError() within the catch block. Unfortunately, when the program reaches the FireError(), it…
J Weezy
  • 3,507
  • 3
  • 32
  • 88
0
votes
2 answers

Move files after upload using PowerShell/WinSCP Script

I am using a PowerShell script generated in WinSCP to sftp files in a certain folder. It runs every Friday morning, but I need it to move the files to another folder after they are uploaded. I tried the MoveFiles and PutFiles command but they…
Jmmitche1984
  • 1
  • 1
  • 2
0
votes
2 answers

Concatenate/append file downloaded from FTP server to one file

Not able to understand how I can use APPEND functionality in the GetFiles() method. I have to append multiple files and download it as single file in my local machine. Will this APPEND functionality work? The code is: # Load WinSCP .NET…
Ratnesh Sharma
  • 145
  • 2
  • 2
  • 11
0
votes
1 answer

How to copy things from one remote directory to another in the same server using WinSCP .NET assembly in C#

Is there a way to copy files from one remote directory to another for example, from .../public_html/Folder1/name1/ to .../public_html/Folder1/name2/ I am using the WinSCP .NET library for this. I have tried to look everywhere on the internet for…
Rohit Pai
  • 76
  • 7
0
votes
1 answer

Extracting tarball C# using WinSCP .NET Assembly

I'm using WinSCP .NET Assembly in C# to transfer a tarball and extracting it. My code works and I managed to copy the files. But my problem starts, when I try to extract them using session.ExecuteCommand. Nothing happens. Trying to debug it I've…
idan357
  • 342
  • 6
  • 17
0
votes
0 answers

Winscp library supports proxy over SFTP?

Winscp library supports for HTTP proxy. Does it support over FTP and SFTP and how to define it?
Kishor Vitekar
  • 537
  • 5
  • 12
0
votes
1 answer

WinSCP Session.GetFiles error No such file or directory

Using WinSCP with variables to automate downloading of specific file from remote root folder. I have no problem connecting, but the code generates error 'No such file or directory' when attempting download. Here's the code: ' Setup session…
TheoH
  • 3
  • 5
0
votes
1 answer

How to connect to a root directory with FTP .net WinSCP C#

I have an application that can perform FTP/SFTP connections but I'm having issues with something, all this time I've been tested it using a remote directory that I knew, but for now I want to get connected to a server to the root directory if I…
Javier Salas
  • 1,064
  • 5
  • 15
  • 38
0
votes
1 answer

Open WinSCP Command window/Open Terminal(Ctrl + T) window directly in Windows environment

Is there a way Ii can open WinSCP Command window/Open Terminal (Ctrl + T) window directly and pass du command to it through code/scripts.
0
votes
0 answers

Getting "Timeout Error" while doing FTP to server in VB6 using Inet control

I am able to FTP using WinSCP client from my local desktop. When i am trying to do it through code(VB6) I am getting timeout error every time. The same code works on server when deployed.So my question is: 1.> Am I missing some network setting…
Suman George
  • 51
  • 3
  • 9
0
votes
1 answer

WinSCP .NET WebDAV Example

I am unable to find a good WebDAV implementation example utilizing WinSCP .NET assembly. Specifically I am looking for some code that will push a file to a WebDAV server. Could someone please provide some sample C# code to help get me started?
Chris1804505
  • 97
  • 1
  • 10
0
votes
1 answer

WinSCP ExecuteCommand with stdin redirection?

Given: var linuxCommmand = "/opt/ndmcli -x"; var linuxOptions = "sel stat pnum=157 detail=yes;\nquit;"; SSH.ExecuteCommand(String.Format("{0} <
John
  • 921
  • 1
  • 9
  • 24
0
votes
0 answers

add_FileTransferProgress crashes file transfer with Timeout error message for WinSCP (Powershell)

I have an script that simply download all the files from given ftp server (backup tool). Everything works fine but it takes hours before complete so I've decided to add some progress info based on WinSCP documentation: function FileTransferProgress…
PolGraphic
  • 3,233
  • 11
  • 51
  • 108
0
votes
1 answer

How to run "sudo su tomcat" from a .NET application

I need to run shell scripts (shutdown scripts for tomcat) with the tomcat user out from a C# .NET application. I tried with the WinSCP .NET assembly. I can login via ssh and run commands. But how to run sudo su tomcat first with the same password I…