Is there a way to call the WinScP saved session and not have WinSCP launch in the foreground. I have a Powershell script that currently makes a SFTP call to a site; however, I'm needing to use a proxy now. So, I thought that the easiest way would be to create a session in WinSCP then call that saved session from my script. My call line is a
Start-Process -FilePath "C:\Program Files...\..\WinSCP.exe" -ArgumentList "SiteName" -Wait -NoWindow
What this does is launch the WinSCP gui, logged me into the site, and then stopped. Is there a command switch to run a batch file? My previous process was running psftp and I had the command line arguments for the batch file. Can WinSCp take parameters to run a batch file?