using .ini vs SessionOptions Powershell
Hello
I have a bunch of scripts getting and putting files to a ftp and sftp server using the sessionOptions.XXX commands in a powershell script.
I would like to use the .ini file instead, so that login credentials are better protected, versus being plain text in all the scripts. (can i have seperate ini files per ftp server?)
So far i got this:
$session = New-Object WinSCP.Session
($session).IniFilePath
I am new to PS, and see there is a get and set option for the IniFilePath Property
I have been however unable to implement this. (i used the gui to creat a .ini file to persuse as well)
I am stuck on how to implement this correctly.
Any syntax aid would be great.
Thanks
I have a bunch of scripts getting and putting files to a ftp and sftp server using the sessionOptions.XXX commands in a powershell script.
I would like to use the .ini file instead, so that login credentials are better protected, versus being plain text in all the scripts. (can i have seperate ini files per ftp server?)
So far i got this:
$session = New-Object WinSCP.Session
($session).IniFilePath
I am new to PS, and see there is a get and set option for the IniFilePath Property
I have been however unable to implement this. (i used the gui to creat a .ini file to persuse as well)
I am stuck on how to implement this correctly.
Any syntax aid would be great.
Thanks