Topic "WinSCPnet.dll installation and usage confusion"

Author Message
lkubler
[View user's profile]

Joined: 2015-02-18
Posts: 7
Location: Wisconsin
Hi,

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. Very Happy

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 http://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:

Quote:
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.

Your thoughts?

Thanks in advance,
Linn
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24555
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 winscp.exe was not included in the assembly package.
Either check the old version of the documentation:
http://winscp.net/eng/docs/library_install?rev=1423667558
Or wait few hours for 5.7 release.
Apologies for your troubles.

Btw:
- You do not need to "register" the assembly to use it from PowerShell. Registering is for COM only.
- Putting the assembly to C:\Windows\SysWOW64 is not a good practice. Just put it to a user folder along with your PowerShell script.
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License