Question about sending hushmail email via vb.net.
Hey coders,i have make email senders in the past with gmail. After many frustrating error messages i was able to change a gmail setting allowing "use of unsecure apps" on my gmail security settings. Now i am trying to send email with my hushmail.com account. I googled their smtp and found them here https://help.hushmail.com/entries/24...ames-and-ports. So i inerted my login info andhushmail smtp stuff where gmails used to be in this code here
Try
Dim SmtpClient As New SmtpClient("smtp.gmail.com", 587)
SmtpClient.Credentials = New Net.NetworkCredential("Your Email Login", "Your Email Password")
SmtpClient.EnableSsl = True
emailmessage.From = New MailAddress("From Email Address")
emailmessage.To.Add("Email Address Being Sent To")
emailmessage.Subject = ("Enter Subject Here")
emailmessage.Body = ("Enter Body Here")
SmtpClient.Send(emailmessage)
MessageBox.Show("Email Sent Successful")
Catch ex As System.Net.Mail.SmtpException
Dim code As System.Net.Mail.SmtpStatusCode = ex.StatusCode
MessageBox.Show(ex.ToString + " : " + code.ToString)
End Try
Tomarow when i login to my computer i can post the actual error message but i think it has something to do with me not being logged in. Can anybody give me some pointers on some setting i might need to import.thanks
Re: Question about sending hushmail email via vb.net.
Quote:
So i inerted my login info andhushmail smtp stuff where gmails used to be in this code here
Read this sentence again, then compare your code to the reality it describes. You'll find a discrepancy.
Re: Question about sending hushmail email via vb.net.
Quote:
Originally Posted by
Sitten Spynne
Read this sentence again, then compare your code to the reality it describes. You'll find a discrepancy.
not sure what you ment but here is the code i used Try
Dim SmtpClient As New SmtpClient("smtp.hushmailmail.com", 587)
SmtpClient.Credentials = New Net.NetworkCredential("my hushmail username", "my hushmail password")
SmtpClient.EnableSsl = True
emailmessage.From = New MailAddress("my hushmail adress")
emailmessage.To.Add("my gmail")
emailmessage.Subject = ("textbox11.text)
emailmessage.Body = (textbox2.text)
SmtpClient.Send(emailmessage)
MessageBox.Show("Email Sent Successful")
Catch ex As System.Net.Mail.SmtpException
Dim code As System.Net.Mail.SmtpStatusCode = ex.StatusCode
MessageBox.Show(ex.ToString + " : " + code.ToString)
End Try
1 Attachment(s)
Re: Question about sending hushmail email via vb.net.