Sending Email with Attachments (VB.NET/ASP.NET)
Category:C#, VB.NET, ASP.NET
Version Compatibility: Visual Basic.NET, ASP.NET
These are two functions to send email, both with optional parameters for attachment files. In the first the optional parameter is a string, so you can attach one file. In the second, it is an ArrayList, so that you can attach multiple files. If you are using this in a Windows forms project, you must add a reference to System.Web. See the comments for full details.
Instructions: Copy the declarations and code below and paste directly into your VB project.