Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Application_error function intermittently catch "File does not exist"

I am using the Application_Error event for handling the exceptions and it catches almost all exceptions correctly. However in some pages it catches with exception "File does not exist" and I am not able to find from where it exactly occurs. When I comment the Application_Error code, surprisingly that web page works fine.

My main concern is how can trace back to the line of code from where it threw to Application_Error function.

like image 249
Anto Varghese Avatar asked Jul 14 '10 04:07

Anto Varghese


1 Answers

Use HttpContext.Current.Request.Url.ToString() to look at the file path of the missing file.

like image 136
Abhi Avatar answered Oct 04 '22 17:10

Abhi