Topic "Accessing COM library via VBA"

Author Message
michaelikane
[View user's profile]

Joined: 2012-03-07
Posts: 1
Location: New York, NY
I am trying to use the library in Office VBA. I have successfully registered it and added the COM as a reference in the VBA editor. However, despite using the VB script examples on this site as a guide, I cannot GetObject WinSCP, much less pass session options to it or use it with other macros I have written.

Does anyone have any samples for opening a session, connecting and putting a file on a server for VBA?
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
<post removed>

Deprecated by
https://winscp.net/eng/docs/library_vb
etienne
[View user's profile]

Joined: 2012-03-19
Posts: 1
Hi,

I am also trying to use WinSCP with VBA but I cannot find the ".NET wrapper for WinSCP console interface" in Tools > References.

Actually I have a portable version of WinSCP, and I could not register the WinSCP.dll assembly.

When trying to register the assembly:
C:\Windows\Microsoft.NET\Framework\v2.0.50727\RegAsm.exe WinSCP.dll /codebase /tlb

I have the following error message:
RegAsm : error RA0000 : Unable to locate input assembly 'WinSCP.dll' or one of its dependencies.

As recommended, the WinSCP.dll file is in the same folder as the portable WinSCP executable

Any idea?

Thank you in advance for your help
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
etienne wrote:
When trying to register the assembly:
C:\Windows\Microsoft.NET\Framework\v2.0.50727\RegAsm.exe WinSCP.dll /codebase /tlb

I have the following error message:
RegAsm : error RA0000 : Unable to locate input assembly 'WinSCP.dll' or one of its dependencies.

There did you get the winscp.dll from?

Did you follow this guide?
https://winscp.net/eng/docs/library_install
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
Overall guide to using WinSCP .NET assembly from VBA has been added:
https://winscp.net/eng/docs/library_vb
_________________
Martin Prikryl
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