Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.
One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.
Public Shared Sub SendGenericEmail(ByVal emailAddress As String, ByVal emailSubject As String, ByVal emailBody As String, _ ByVal attachmentPath As String) Dim oSMTP As New System.Net.Mail.SmtpClient Dim replaceFields As New ListDictionary() Dim message As New MailDefinition() message.Subject = emailSubject message.IsBodyHtml = True Dim oMessage As New MailMessage() oMessage = message.CreateMailMessage(emailAddress, replaceFields, New LiteralControl()) oMessage.DeliveryNotificationOptions = DeliveryNotificationOptions.OnFailure oMessage.ReplyTo = New MailAddress(DTHClassLibrary.DTH.StaticVariables.ReplyToAddress) oMessage.Body = emailBody If attachmentPath <> String.Empty Then oMessage.Attachments.Add(New Attachment(attachmentPath)) End If ' Send the message Try oSMTP.Send(oMessage) Catch ex As Exception Throw ex End Try End Sub
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.