Note that there are some explanatory texts on larger screens.

plurals
  1. POsend email C# smtpclient using ibm lotus
    primarykey
    data
    text
    <p>I have gone through all the answers ... this is my situation</p> <ol> <li>i need C# code to send email using ibm lotus account ( have username and password)</li> <li>the server from which our app sends out emails is authorized</li> <li>no firewall stopping </li> <li>IBM lotus client is not installed on the server. so cannot use interop.domino.dll</li> <li><p>the SMTP service is exposed. i have ip address and port. cant telnet to it and test it becasue server does not have telnet and they will not allow us enabling it</p></li> <li><p>When i run the code below i get connection actively refused exception.</p></li> </ol> <p>Is there any working code sample .. or am i missing something here .. any trouble shooting tips will be appreciated.</p> <p>try { MailMessage message = new MailMessage(); message.From = new MailAddress(from.Text);</p> <pre><code> message.To.Add(new MailAddress(to.Text)); //message.To.Add(new MailAddress("recipient2@foo.bar.com")); //message.To.Add(new MailAddress("recipient3@foo.bar.com")); //message.CC.Add(new MailAddress("carboncopy@foo.bar.com")); message.Subject = "Test email from cogniti"; message.Body = "Test email from Cogniti"; SmtpClient client = new SmtpClient(); client.Port = Convert.ToInt32(port.Text); client.Host = smtp.Text; client.Credentials = new System.Net.NetworkCredential(username.Text, passwordBox1.Password); //client.UseDefaultCredentials = true; if (ssl.Text.Equals("1")) client.EnableSsl = true; else if (ssl.Text.Equals("2")) client.EnableSsl = false; else client.EnableSsl = false; client.UseDefaultCredentials = false; client.Send(message); MessageBox.Show("Message Sent to: " + to.Text); } catch (Exception e3) { MessageBox.Show(e3.Message); MessageBox.Show(e3.InnerException.ToString()); MessageBox.Show(e3.Source); MessageBox.Show(e3.StackTrace); } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload