Dim from As New EmailAddress("neo@xxx.com.tw", "Neo")
Dim sto As New EmailAddress("neo@yyy.com.tw", "XYZ")
Dim msg As New OpenSmtp.Mail.MailMessage(from, sto)
msg.Subject = "測試 OpenSmtp .Net SMTP component"
msg.Body = "Neo's BLOG 測試"
msg.Charset = "big5"
'這個很重要,一定要設成 big5 或 UTF-8 才能正常顯示中文
msg.AddAttachment("c:\reply\test.gif")
Dim Smtp As New Smtp("www.xxx.com.tw", 25)
Smtp.Username = "neo" '有支援 SMTP 認證
Smtp.Password = "xyz"
Smtp.SendMail(msg)