Server Error in '/Webapplication1' Application.
------------------------------------------------------------Object reference not set to an instance of an object. 
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.Source Error: 
Line 1:  <%@ Page language="c#" Codebehind="Login.aspx.cs" AutoEventWireup="false" Inherits="Webapplication1.Login" %>
Line 2:  <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
Line 3:  <HTML>
 Source File: D:\Webapplicaton1\Login.aspx    Line: 1 Stack Trace: 
[NullReferenceException: Object reference not set to an instance of an object.]
   System.Web.UI.Control.get_Controls()
   System.Web.UI.Control.System.Web.UI.IParserAccessor.AddParsedSubObject(Object obj)
   ASP.Login_aspx.__BuildControlTree(Control __ctrl) in D:\Webapplication1\Login.aspx:1
   ASP.Login_aspx.FrameworkInitialize() in f:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary ASP.NET Files\soxaweb\c91d8acf\47cd4659\ylczm0jk.0.cs:0
   System.Web.UI.Page.ProcessRequest()
   System.Web.UI.Page.ProcessRequest(HttpContext context)
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication+IExecutionStep.Execute() +179
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +87 
-------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573

解决方案 »

  1.   

    所有的webapp都是一樣,並非是對象未實例化,此其一其二是,我剛剛還在運行程序,一直都很正常其三是,以前也偶爾出現過,但是重新編譯一下sln就可以了,但這次不行所以我覺得有可能是.net2003工具出錯了
      

  2.   

    估计是.net framework 出错了
      

  3.   

    1。
    关闭 solution 重新打开看看, 然后 rebuild2。
    breakpoint 》 debug 》 trace
      

  4.   

    1. 關閉sln & .net2003;
    2. 開啓.net2003,並create new web project無任何人爲寫入的代碼内容,直接運行,一樣出現這種問題
    謝謝樓上各位兄弟!
    問題未解決等待中...