I want to send an e-mail when a setup occurs on my indicator. I can get the setup to print to the Output Box, but the e-mail log gives an error message.
My code is as follows
SendMail("[email protected]", "[email protected]", "Trade Alert", "CxTSFup");
and the error message from the log is
Failed to send mail: System.Net.Mail.SmtpException: Service not available, closing transmission channel. The server response was: Cannot connect to SMTP server 64.38.21.160 (64.38.21.160:25), connect timeout
at System.Net.Mail.SmtpConnection.GetConnection(Strin g host, Int32 port)
at System.Net.Mail.SmtpTransport.GetConnection(String host, Int32 port)
at System.Net.Mail.SmtpClient.GetConnection()
at System.Net.Mail.SmtpClient.Send(MailMessage message)
at NinjaTrader.Cbi.Globals.SendMailNow(String from, String to, String cc, String subject, String body, String[] attachmentPaths)
at NinjaTrader.Cbi.Globals.MailThreadProc()
---------------
[IMG]file:///C:/Users/BILLR%7E1/AppData/Local/Temp/msohtmlclip1/01/clip_image001.gif[/IMG] Can anyone help to solve this problem. Thank you
I tried to put a screen shot of the Options > Misc window, but it did not work
Comment