首页上一页 1 下一页尾页 1 条记录 1/1页
asp.net 从入门到精通
发表在ASP.NET图书答疑
2009-07-17
是否精华
是
否
版块置顶:
是
否
我运行程序时老是出错“/WebSite1”应用程序中的服务器错误。
--------------------------------------------------------------------------------
类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.Web.HttpException: 类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。
源错误:
执行当前 Web 请求期间生成了未处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。
堆栈跟踪:
[HttpException (0x80004005): 类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。]
System.Web.UI.Page.VerifyRenderingInServerForm(Control control) +301
System.Web.UI.WebControls.TextBox.AddAttributesToRender(HtmlTextWriter writer) +119
System.Web.UI.WebControls.WebControl.RenderBeginTag(HtmlTextWriter writer) +36
System.Web.UI.WebControls.TextBox.Render(HtmlTextWriter writer) +32
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +74
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +291
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +49
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +234
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +53
System.Web.UI.Control.Render(HtmlTextWriter writer) +31
System.Web.UI.Page.Render(HtmlTextWriter writer) +39
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +74
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +291
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +49
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5539
请问如何解决
--------------------------------------------------------------------------------
类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.Web.HttpException: 类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。
源错误:
执行当前 Web 请求期间生成了未处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。
堆栈跟踪:
[HttpException (0x80004005): 类型“TextBox”的控件“TextBox1”必须放在具有 runat=server 的窗体标记内。]
System.Web.UI.Page.VerifyRenderingInServerForm(Control control) +301
System.Web.UI.WebControls.TextBox.AddAttributesToRender(HtmlTextWriter writer) +119
System.Web.UI.WebControls.WebControl.RenderBeginTag(HtmlTextWriter writer) +36
System.Web.UI.WebControls.TextBox.Render(HtmlTextWriter writer) +32
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +74
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +291
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +49
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +234
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +53
System.Web.UI.Control.Render(HtmlTextWriter writer) +31
System.Web.UI.Page.Render(HtmlTextWriter writer) +39
System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +74
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +291
System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +49
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5539
请问如何解决