When I compile .NET solution, which is an ASP.NET 3.5 website project and a few class libraries, sometimes we get COMPILE error "Object reference not set to an instance of an object". Doesn't give you any additional information, like it usually does - which project, file, li开发者_如何转开发ne of code or anything like that. Usually if you stop and re-compile it disappears but re-appears once in a while. Some developers think it comes from report control that we use to view SSRS reports but no one is certain. Same happens with everyone on a project. How would you investigate this kind of problem, what would you look at first, and what kinds of tools would you use.
It could be that your designer files are out of sync with the aspx. There maybe references to controls that no longer exist in the web form.
I'd also suggest taking a look at the Output window (View > Output). That might give you more clues as to where the error is happening.
精彩评论