Error: Object reference not set to an instance of an object

woodsrr

New member
Joined
Aug 3, 2007
Messages
3
Programming Experience
10+
Our website has about 20+ web pages and we get about 7000+ web hits a day.

I have code which sends me an email anytime someone encounters and unhandled error, showing me the error stack and what page they were on when the error happened.

About 3 to 6 times a week I get this error:

Object reference not set to an instance of an object

I know that this is usually caused by an object not being instantiated with the New command. What is puzzling to me is; I have 7000+ web hits and less then one error a day, that means that the code works better then 99% of the time. Also I don’t just get the error on one page which means that it is either in some code that is shared in all pages like a custom control or that it has nothing to do with my code but is related to maybe a lost internet connection by our users or something else like that.

Has anyone encountered a similar problem, or know of a possible cause?

Thanks for any help
 
That is a very generic error that could be anywhere in the code. Have you possibly tried getting a bit more error information sent to you so you can see exactly where this error is coming from.

But based on your statistics that is a pretty solid web application. I have worked with applications that when I saw the ammount of errors it was throwing, swallowing, and ignoring my head almost exploded. But if you get more information from the error you should be able to figure out the exact line where this is happening and should be able to easily correct the problem with some sort of catch block or possibly by just making sure that variables are instantiated before being called.
 
The main reason for the post was to see if anyone else is having a simular problem which they have been able to trace back to something other then code. Like, network issues or server hiccups...

It's Been a bugger...:D
 
Back
Top