Rajendra Meena

Rajendra Meena

  • NA
  • 10
  • 14.9k

I want to submit enquiry form for save this information for email id, This is work on local host but show the error on line time. ple send me response

Jul 2 2011 4:22 AM


Exception Details: System.Security.SecurityException: Request for the permission of type 'System.Net.Mail.SmtpPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.




Source Error:

Line 48: Line 49: System.Net.NetworkCredential mailAuthentication = new System.Net.NetworkCredential(Email, Password); Line 50: SmtpClient mSmtpClient = new SmtpClient(Host, Port); Line 51: mSmtpClient.EnableSsl = true; Line 52: mSmtpClient.UseDefaultCredentials = false;


Answers (1)