MailAddress mailfrom = new MailAddress("info@breakview.com"); MailAddress mailto = new MailAddress("info@breakview.com"); MailMessage newmsg = new MailMessage(mailfrom, mailto); newmsg.Subject = "Resume Posted"; newmsg.Body = "See Attached Resume"; if (FileUpload1.HasFile) { string ImgPath1 = Server.MapPath("~/resume/" + Guid.NewGuid() + FileUpload1.FileName); FileUpload1.SaveAs(ImgPath1); Attachment att = new Attachment(ImgPath1); newmsg.Attachments.Add(att); } SmtpClient smtp = new SmtpClient("relay-hosting.secureserver.net", 25); smtp.UseDefaultCredentials = false; smtp.Credentials = new NetworkCredential("info@breakview.com", "######"); smtp.Send(newmsg);
FileUpload1.SaveAs(ImgPath1);
Error is Access to the path 'D:\Hosting\12049298\html\breakview\resume\b6609e03-9e2f-411b-b8e8-49556740d989debug.log' is denied.
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)