Description: I have used three FileUploadcontrols in this example so you can
send three attachments with the email. But if you want to send more attachments
with email then just add more FileUpload controls as per requirement. There is also option of Cc(Carbon copy) and Bcc( Blank Carbon Copy) option to send mail like Gmail, Yahoo, Rediffmail etc mail servers.

<asp:RequiredFieldValidatorID="rfvFrom"runat="server"ErrorMessage="Email
address can't be left blank"ControlToValidate="txtFrom"Display="Dynamic"ForeColor="#FF3300"SetFocusOnError="True"></asp:RequiredFieldValidator>

<asp:RequiredFieldValidatorID="rfvTo"runat="server"ErrorMessage="Email
address can't be left blank"ControlToValidate="txtTo"Display="Dynamic"ForeColor="#FF3300"SetFocusOnError="True"></asp:RequiredFieldValidator>

Notice thatin this article I have also used the
RegularExpression validation control and RequiredFiledvalidator validation control
to validate the Email Id’s in the “To”,"Cc","Bcc" and “From” field. To get detailed
knowledge on RegularExpression validation control and RequiredFieldValidator
validation control read my articles on Validation controls in asp.net.

C#.Net Codeto send mail with
multiple attachments using asp.net with C# and Vb.Net

smtp.Credentials = new
System.Net.NetworkCredential("YourGmailId@gmail.com", "YourGmailPassword"); //Or
use your Smtp Email ID and Password if Host is not Gmail

smtp.EnableSsl = true;

smtp.Send(mail);

ClearControls();//Clear
all controls after sending mail

lblStatus.Text = "Email
sent successfully";

}

catch (Exception ex)

{

lblStatus.Text = "Email
couldn't be sent";

}

}

protectedvoid ClearControls()

{

txtFrom.Text = string.Empty;

txtTo.Text = string.Empty;

txtCc.Text = string.Empty;

txtBcc.Text = string.Empty;

txtSubject.Text = string.Empty;

txtBody.Text = string.Empty;

}

VB.Net Code to send mail with
multiple attachments using asp.net with C# and Vb.Net

Note: Design the form same as C#.Net
page(.aspx) above but just change the line <asp:ButtonID="btnSendMail"runat="server"Text="Send
Mail"OnClick="btnSendMail_Click"/> with <asp:ButtonID="btnSendMail"runat="server"Text="Send
Mail"/>

smtp.Credentials = New
System.Net.NetworkCredential("YourGmailId@gmail.com", "YourGmailPassword") 'Or
use your Smtp Email ID and Password if Host is not Gmail

smtp.EnableSsl = True

smtp.Send(mail)

ClearControls() 'Clear
all controls after sending mail

lblStatus.Text = "Email
sent successfully"

Catch ex AsException

lblStatus.Text = "Email
couldn't be sent"

EndTry

EndSub

ProtectedSub ClearControls()

txtFrom.Text = String.Empty

txtTo.Text = String.Empty

txtCc.Text = String.Empty

txtBcc.Text = String.Empty

txtSubject.Text = String.Empty

txtBody.Text = String.Empty

EndSub

Now over to you:

"If you like my work; you can appreciate by leaving your comments,
hitting Facebook like button, following on Google+, Twitter, Linked in and
Pinterest, stumbling my posts on stumble upon and subscribing for receiving
free updates directly to your inbox . Stay tuned and stay connected for more
technical updates."

The FileUpload control doesn’t work for uploading image using Asynchronous postback when placed in the Update Panel since FileUpload control required full postback to get the image.Read the article to solve this issue:fileupload control cause problem in update panelSolution to FileUpload control is not working in UpdatePanelhttp://www.webcodeexpert.com/2013/08/fileupload-control-in-update-panel.html

If you have any question about any post, Feel free to ask.You can simply drop a comment below post or contact via Contact Us form. Your feedback and suggestions will be highly appreciated. Also try to leave comments from your account not from the anonymous account so that i can respond to you easily..