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

jorgea

Cannot

It looks like you cannot do this
martin

Re: Session in powershell

You cannot (at least not in any documented and reliable way), the assembly by purpose runs independently from the GUI configuration.
Fady01

Session in powershell

Hello,

I would like to know how I can call a session that i have already register in the winscp GUI

All exemple that I found require to spefify the session configuration in the powershell script :

# Setup session options
$sessionOptions = New-Object WinSCP.SessionOptions
$sessionOptions.Protocol = [WinSCP.Protocol]::Sftp
$sessionOptions.HostName = "example.com"
$sessionOptions.UserName = "user"
$sessionOptions.Password = "mypassword"
$sessionOptions.SshHostKeyFingerprint = "ssh-rsa 1024 xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx"

$session = New-Object WinSCP.Session

try
{
# Connect
$session.Open($sessionOptions)


Any help would be appreciate