Posted: 2015-02-18 15:11
I need to create a reoccuring scheduled SFTP process and think WinSCPnet with PowerShell scripting will do the job. I don't have much experience with PowerShell but I guess this is my chance to learn something new.
So I downloaded winscp556automation.zip, unzipped it and copied the dll into the C:\windows\SysWOW64 folder on my Windows 7 Pro 64-bit desktop. I did the registration as described on this page https://winscp.net/eng/docs/library_install#registering.
Then I borrowed a sample script from elseware on this site and gave it a try but received this error message:
The winscp.exe executable was not found at location of the assembly (C:\Windows\SysWOW64), nor in an installation path. You may use Session.ExecutablePath property to explicitly set path to winscp.exe.
So I added the Session.ExecutablePath to point to SysWOW64 and now I get this message:
The specified executable is not a valid application for this OS platform.
Then I noticed this comment on that installation page:
The package includes the assembly itself (winscpnet.dll) and a required dependency, WinSCP executable winscp.exe.
The binaries interact with each other and must be kept in the same folder for the assembly to work.
So I looked at the zip file I downloaded again and all I see is the dll and two txt files. Color me confused, where is the WinSCP executable? Shouldn't it be in the zip file I downloaded or do I need to install WinSCP for this dll library to function? For my project I'm thinking I don't really need the full WinSCP, unless it is to make the .Net dll funciton.
When I take this live it will be on a server and I would really prefer not to have to install another application on the server.
Thanks in advance,
Location: Prague, Czechia
It's inconsistency on our side.
We have updated the documentation for 5.7 release already two days back, expecting a release on the same day. But due to technical problems, the release was posponed until today.
In the old versions, the
Either check the old version of the documentation:
Or wait few hours for 5.7 release.
Apologies for your troubles.
- You do not need to "register" the assembly to use it from PowerShell. Registering is for COM only.
- Putting the assembly to
You can post new topics in this forum
And it's free!