Password Prompt


I have a powershell script that works OK - however, the WinSCP requests password re-entering after couple of hours. When this happens the powershell script stops and the transfer of files is terminated.

I want to the script to continue when the password is prompted by WinSCP - How can I achieve that in the code?


Your script would need to trap that error condition and re-submit the password.