我是ASP.NET的新手,刚被分配为公司的CMS(内容管理系统)Web应用程序(用c#.net编写)创建安装程序。
将Xcopy
开发用于任何客户的服务器时,它工作正常。但是,在.msi
中创建VS2010
安装程序并安装应用程序后,内部的某些Web表单无法显示,但出现以下异常:
'/cms-vodoke'
应用程序中的服务器错误。
对象引用未设置为对象的实例。
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.
异常详细信息:
System.NullReferenceException: Object reference not set to an instance of an object.
来源错误:
[No relevant source lines]
Source File: c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\cms-vodoke\9f7fc69b\77cb7e4\App_Web_nlj0wmz0.7.cs Line: 0
堆栈追踪:
[NullReferenceException: Object reference not set to an instance of an object.]
CuteEditor.Impl.b..ctor(Type type, String key) +77
CuteEditor.a.i(HtmlTextWriter A_0) +156
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
ASP.cmscontrol_cm_rteditor_catwallpaper_ascx.__RenderuiRTEditor(HtmlTextWriter __w, Control parameterContainer) in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\cms-vodoke\9f7fc69b\77cb7e4\App_Web_nlj0wmz0.7.cs:0
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +130
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +245
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
ASP.cmsadmin_cm_category_form_aspx.__RenderpgContent1(HtmlTextWriter __w, Control parameterContainer) in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\cms-vodoke\9f7fc69b\77cb7e4\App_Web_xq4tbmg1.0.cs:0
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +130
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +245
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer) +314
System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer) +47
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
ASP.cmsadmin_system_master.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in c:\inetpub\wwwroot\cms-vodoke\cmsadmin\system.master:28
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +130
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +245
System.Web.UI.Page.Render(HtmlTextWriter writer) +39
System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +11249515
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5273
Web安装项目构建良好,安装没有任何问题,但应用程序无法正常工作,即使在我的本地计算机上也是如此。我被这几天绊倒了,
任何人都可以帮我确定这个问题的来源吗?非常感谢。
答案 0 :(得分:0)
这不是一条线,它会显示错误是什么以及它被抛出的原因。由于没有可读取的代码行,因此我也很难找到错误的根源。
一般来说,当您尝试引用空值或者对象类型不是在舞台上预期的那样时,会抛出此异常。您正在处理的依赖项或您为此应用程序工作的程序集文件可能是错误。
页面是空的吗?可能会抛出此错误的代码是什么?
http://msdn.microsoft.com/en-us/library/system.nullreferenceexception(v=vs.110).aspx转到此处阅读例外信息。
答案 1 :(得分:0)
请转到部署了应用程序的服务器,然后查看Windows事件日志。您应该能够在那里看到详细的事件日志。请粘贴与您的应用程序相关的那个,以便我们可以看到正在发生的事情。