E-mail notification, help needed

Advertisement

costasppc
Joined:
Posts:
3
Location:
Athens

E-mail notification, help needed

Hello,

I am using WinSCP command line (great tool) with the following script:

option batch continue
option confirm off
open <USER>@DOMAIN -passive=on
put C:\FiletoUpload\file
exit


I need to add an e-mail notification to get success or error. I have found in the WinSCP site the following script, but how to insert it in my script?

winscp.com /script=example.txt
if errorlevel 1 goto error

echo Success
sendmail.exe -t < success_mail.txt
goto end

:error
echo Error!
sendmail.exe -t < error_mail.txt

:end

Best regards

Kostas

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
41,450
Location:
Prague, Czechia

Re: E-mail notification, help needed

That code is a Windows batch file that runs WinSCP (and its script). Not other way around.

Reply with quote

Advertisement

Advertisement

You can post new topics in this forum