Hi,
As you use here...
uploadfile.SaveAs(Server.MapPath("~/Upload/MailAttachments/") + fileName);
str += fileName + ",";
Modified :
string path = Server.MapPath("~/Upload/MailAttachments/") + fileName;
uploadfile.SaveAs(Server.MapPath(path);
str = "Upload/MailAttachments/" + fileName;
// here you want to add multiple files so beware about last comma...(I use it as single file. first try this.)
// one more suggestion you use filename as uploaded file name, But I think you can generate a random string for this for all time...
or a alternate method also you can try I describe in
my blog[
^].
Hope it will help you.
Thanks