Unable to create log file error
Using WinSCP .NET assembly, I'm getting this error:
Thanks,
Lee
It works if I run the command prompt as administrator. Is there a way to change the location WinSCP uses to log?2021-05-04 15:24:39,529 [1] ERROR Helpers.SftpProcessor - WinSCP.SessionLocalException: WinSCP process terminated with exit code 1. Error output was "Can't open log file 'C:\Users\Lee M\AppData\Local\Temp\2\wscp2FB8.0259F9D2.tmp'.
System Error. Code: 2.
The system cannot find the file specified
Error occurred during logging. Cannot continue.". Response log file C:\Users\Lee M\AppData\Local\Temp\2\wscp2FB8.0259F9D2.tmp was not created. This could indicate lack of write permissions to the log folder or problems starting WinSCP itself.
at WinSCP.Session.Open(SessionOptions sessionOptions)
at Helpers.SftpProcessor.SetUpRemoteFolderStructure() in C:\Repos\SftpProcessor\Main\SftpProcessor\Helpers\SftpProcessor.cs:line 291
Thanks,
Lee