I am using Log4Net and have setup it up in the way describe in the site and forums. But I am having a very strange issue in the Ilog it is crashing some methods but not all. The following is an example of a routine that is causing crash. Might I add that
it only happens when I call ex.InnerException.ToString()) not when I call ex.ToString()
Member
7 Points
62 Posts
Log4net Causing error
Mar 30, 2016 10:19 AM|david38ni|LINK
I am using Log4Net and have setup it up in the way describe in the site and forums. But I am having a very strange issue in the Ilog it is crashing some methods but not all. The following is an example of a routine that is causing crash. Might I add that it only happens when I call ex.InnerException.ToString()) not when I call ex.ToString()
All-Star
43761 Points
18740 Posts
Re: Log4net Causing error
Mar 30, 2016 10:42 AM|mgebhard|LINK
Most likely the inner exception null.
Also you're ignoring the current exception.
Please see the following reference docs from MSDN.
http://www.asp.net/web-forms/overview/getting-started/getting-started-with-aspnet-45-web-forms/aspnet-error-handling
All-Star
120084 Points
27963 Posts
Moderator
MVP
Re: Log4net Causing error
Mar 30, 2016 10:44 AM|ignatandrei|LINK
Did you verify before that ex.InnerException is not null?