Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

Guest

Re: Create new WinSCPnet.Session Object in VBA fails

martin wrote:

Are you getting the error on Set mySession = New WinSCPnet.Session ?

Sorry for not beeng back earlier ;-)
Yes, the error appears exactly on that line
martin

Re: Create new WinSCPnet.Session Object in VBA fails

Are you getting the error on Set mySession = New WinSCPnet.Session ?
hans.wirz@xmv.ch

Create new WinSCPnet.Session Object in VBA fails

Hi I'd like to use your .Net wrapper to do some FTP-Stuff within MS Access 2010 with VBA.
As I try to create a new Session-Objekt, I allways get an Automation-Error ([-2146233321] Automatisierungsfehler).

I did download the latest Assembly and registered as written in your Website.
In Access the TLB is visible after registration and 'compiling' the VBA-Code went without errors

The Code which fails looks like this:
Sub SessionOpen()

    If Not mySession Is Nothing Then
        mySession.Dispose
    End If
    Set mySession = New WinSCPnet.Session
   
    On Error GoTo er
   
    mySession.Open GetSessionOptions
   
    GoTo finish
er:
    handleError True
   
finish:
       
End Sub



Is there something else I've probably missed to get the Wrapper running?
I use Windows 10 on a 64bit Dell-Maschine.

I appreciate your help
Kind regards
Hans