I am working on MVC application which has many views. Some of them are working fine.
And another view gives me an error: An error occurred while processing your request.
An application was working fine before nothing has changed recently and suddenly it has started showing the above error.
In my web.config,
<customErrors mode="On" />
View output is,
<div id="page-wrapper">
<p align="right"><b>Welcome,</b></p>
Error.
An error occurred while processing your request.
<hr />
<footer>
<p>© 2018 -</p>
</footer>
</div>
<!-- /#page-wrapper -->
</div>
In It should load the respective view by calling controller action
public ActionResult Test(String Organisation = "", String BusinessArea = "", String ApplicationName = "")
{
try
{
return View("~/Views/CompanyUsage/Test.cshtml", objLMT);
}
catch (Exception ex)
{
throw ex;
}
}
Below is the Test view,
I am not getting any clue why application behaving in such way. Kindly guide.
Update:
After changing i am getting below error
Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.
Exception Details: System.Security.SecurityException: The source was not found, but some or all event logs could not be searched. Inaccessible logs: Security.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.