SFTPExecutable needs to be defined in app.config to point to

Advertisement

Guest

SFTPExecutable needs to be defined in app.config to point to

Hello!

Can you provide an example on how to define the SFTPExecutable in a web.config for VB.NET?

It's the only thing holding me up right now :)

Thank you very much!

Reply with quote

Advertisement

samf
Guest

Do I need to wait till then next release?

The WinSCP .NET assembly will be released with the 5.0.6 beta in few weeks.

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
41,518
Location:
Prague, Czechia

Re: SFTPExecutable needs to be defined in app.config to point to

sorry, I have no idea what the SFTPExecutable is. Can you give us more details.

Reply with quote

Advertisement

Guest

Re: SFTPExecutable needs to be defined in app.config to point to

martin wrote:

sorry, I have no idea what the SFTPExecutable is. Can you give us more details.

I'm getting an error write over here:

With winscp.StartInfo
' SFTPExecutable needs to be defined in app.config to point to winscp.com
Try
.FileName = "C:\Program Files (x86)\WinSCP\WinSCP.exe" 'AppSettings("SFTPExecutable")
If .FileName Is Nothing OrElse .FileName.Length = 0 Then Throw (New Exception("from PutSFTP: SFTPExecutable not set in config file."))
Catch ex As Exception
errmsg = ex.Message
Return False
End Try

Thanks!

Reply with quote

moose3322
Guest

SFTPExecutable needs to be defined in app.config to point to

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<appSettings>
<add key="SFTPExecutable" value="C:\Program Files (x86)\WinSCP\WinSCP.com"/>
</appSettings>
</configuration>

Reply with quote

bobr
Guest

SFTPExecutable needs to be defined in app.config to point to

If you are having trouble remembering where to modify the app.config file, look in your "Solution Explorer" window in the VB.net editor (C# and C++ might be slightly different). I use various editors, so sometimes it is difficult to remember where everything is. My App.config looks like the following, and seems to work.

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
</startup>
<appSettings>
<add key="SFTPExecutable" value="C:\Program Files (x86)\WinSCP\WinSCP.com"/>
</appSettings>
</configuration>

Reply with quote

Advertisement

You can post new topics in this forum