Thanks Martin, that works.. :)
Before posting, please read how to report bug or request support effectively.
Bug reports without an attached log file are usually useless.
Still can't get logging working though - using this entry;
$session = New-Object WinSCP.Session
$session.SessionLogPath = "C:\scripts\logs\script.xml"
...but not sure where to put it in the script. Have tried several options but, although it doesn't throw an error, it also doesn't create a log file.
.xmlfor a session log file. Use for example
TransferOptionsis the 7th, not the 5th argument of the
2016-O8-01, you have a letter, not a digit.