cwmathew
We recently purchased two licenses for the pro version which supports scripting. Was the PrivateKey property left out of the “Application” layer?
The following works fine, has it uses the library which I don’t need as I only have two servers…
[codebox]
Dim loEarlyConnection As sfFTPLib.SFTPConnection = New sfFTPLib.SFTPConnection
Dim loEarlyKeyManager As sfFTPLib.KeyManager = New sfFTPLib.KeyManager
loEarlyConnection.Host = "123.45.679.11"
loEarlyConnection.Username = "UserName"
loEarlyConnection.Port = 22
loEarlyConnection.LogFile = "c:\TestFTPLog.log"
loEarlyConnection.PrivateKey = loEarlyKeyManager.LoadFile("c:\Keys\PrivateKey.ppk", "")[/codebox]
Using the Application does not...
[codebox]
Dim loFTPApplication As Object = CreateObject("SmartFTP.Application")
Dim loConnection As Object = loFTPApplication.CreateObject("sfFTPLib.SFTPConnection")
Dim loKeyManager As Object = loFTPApplication.CreateObject("sfFTPLib.KeyManager")
loConnection.Host = "123.45.679.11"
loConnection.Username = "UserName"
loConnection.Port = 22
loConnection.LogFile = "c:\TestFTPLog.log"
loConnection.PrivateKey = loKeyManager.LoadFile("c:\Keys\PrivateKey.ppk", "")[/codebox]
Thanks
The following works fine, has it uses the library which I don’t need as I only have two servers…
[codebox]
Dim loEarlyConnection As sfFTPLib.SFTPConnection = New sfFTPLib.SFTPConnection
Dim loEarlyKeyManager As sfFTPLib.KeyManager = New sfFTPLib.KeyManager
loEarlyConnection.Host = "123.45.679.11"
loEarlyConnection.Username = "UserName"
loEarlyConnection.Port = 22
loEarlyConnection.LogFile = "c:\TestFTPLog.log"
loEarlyConnection.PrivateKey = loEarlyKeyManager.LoadFile("c:\Keys\PrivateKey.ppk", "")[/codebox]
Using the Application does not...
[codebox]
Dim loFTPApplication As Object = CreateObject("SmartFTP.Application")
Dim loConnection As Object = loFTPApplication.CreateObject("sfFTPLib.SFTPConnection")
Dim loKeyManager As Object = loFTPApplication.CreateObject("sfFTPLib.KeyManager")
loConnection.Host = "123.45.679.11"
loConnection.Username = "UserName"
loConnection.Port = 22
loConnection.LogFile = "c:\TestFTPLog.log"
loConnection.PrivateKey = loKeyManager.LoadFile("c:\Keys\PrivateKey.ppk", "")[/codebox]
Thanks