System.Xml.XmlException: 缺少根元素
说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。
异常详细信息: System.Xml.XmlException: 缺少根元素。
源错误:
[没有相关的源行]
源文件: c:\windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\a840fbda\97b8902a\App_Web_2c_wd-pi.6.cs 行: 0
堆栈跟踪:
[XmlException: 缺少根元素。]
System.Xml.XmlTextReaderImpl.Throw(Exception e) +76
System.Xml.XmlTextReaderImpl.ThrowWithoutLineInfo(String res) +61
System.Xml.XmlTextReaderImpl.ParseDocumentContent() +3979352
System.Xml.XmlTextReaderImpl.Read() +151
System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace) +112
System.Xml.XmlDocument.Load(XmlReader reader) +108
System.Xml.XmlDocument.Load(String filename) +87
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager.ReviseConfig() +165
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager..cctor() +240
[TypeInitializationException: “Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager”的类型初始值设定项引发异常。]
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager.LoadConfig() +0
Zhiyuan.Web.CN.admin.code.GeneralConfig..cctor() +108
[TypeInitializationException: “Zhiyuan.Web.CN.admin.code.GeneralConfig”的类型初始值设定项引发异常。]
Zhiyuan.Web.CN.admin.code.GeneralConfig.ResetConfig() +0
Zhiyuan.Web.CN.Parentpage..ctor() +177
Zhiyuan.Web.CN.shownews..ctor() +108
ASP.shownews_aspx..ctor() in c:\windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\a840fbda\97b8902a\App_Web_2c_wd-pi.6.cs:0
[TargetInvocationException: 调用的目标发生了异常。]
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandle& ctor, Boolean& bNeedSecurityCheck) +0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache) +86
System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) +230
System.Activator.CreateInstance(Type type, Boolean nonPublic) +67
System.Web.UI.PageParser.GetCompiledPageInstance(VirtualPath virtualPath, String inputFile, HttpContext context) +224
System.Web.UI.PageParser.GetCompiledPageInstance(String virtualPath, String inputFile, HttpContext context) +121
URLRewriter.RewriterFactoryHandler.GetHandler(HttpContext context, String requestType, String url, String pathTranslated) +675
System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig) +193
System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +93
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155
异常详细信息: System.Xml.XmlException: 缺少根元素。
源错误:
[没有相关的源行]
源文件: c:\windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\a840fbda\97b8902a\App_Web_2c_wd-pi.6.cs 行: 0
堆栈跟踪:
[XmlException: 缺少根元素。]
System.Xml.XmlTextReaderImpl.Throw(Exception e) +76
System.Xml.XmlTextReaderImpl.ThrowWithoutLineInfo(String res) +61
System.Xml.XmlTextReaderImpl.ParseDocumentContent() +3979352
System.Xml.XmlTextReaderImpl.Read() +151
System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace) +112
System.Xml.XmlDocument.Load(XmlReader reader) +108
System.Xml.XmlDocument.Load(String filename) +87
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager.ReviseConfig() +165
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager..cctor() +240
[TypeInitializationException: “Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager”的类型初始值设定项引发异常。]
Zhiyuan.Web.CN.admin.code.GeneralConfigFileManager.LoadConfig() +0
Zhiyuan.Web.CN.admin.code.GeneralConfig..cctor() +108
[TypeInitializationException: “Zhiyuan.Web.CN.admin.code.GeneralConfig”的类型初始值设定项引发异常。]
Zhiyuan.Web.CN.admin.code.GeneralConfig.ResetConfig() +0
Zhiyuan.Web.CN.Parentpage..ctor() +177
Zhiyuan.Web.CN.shownews..ctor() +108
ASP.shownews_aspx..ctor() in c:\windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\a840fbda\97b8902a\App_Web_2c_wd-pi.6.cs:0
[TargetInvocationException: 调用的目标发生了异常。]
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandle& ctor, Boolean& bNeedSecurityCheck) +0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache) +86
System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) +230
System.Activator.CreateInstance(Type type, Boolean nonPublic) +67
System.Web.UI.PageParser.GetCompiledPageInstance(VirtualPath virtualPath, String inputFile, HttpContext context) +224
System.Web.UI.PageParser.GetCompiledPageInstance(String virtualPath, String inputFile, HttpContext context) +121
URLRewriter.RewriterFactoryHandler.GetHandler(HttpContext context, String requestType, String url, String pathTranslated) +675
System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig) +193
System.Web.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +93
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +155
...全文
相关推荐
System.Xml.XmlException(解决方案).md
项目中碰到的,记录一下解决方案
详解C#借助.NET框架中的XmlTextReader类读取XML的方法
主要介绍了详解借助.NET框架中的XmlTextReader类读取XML的方法,这种方式的执行效率还是比较令人满意的,需要的朋友可以参考下
C#解析XML文件并用WinForm显示
自己写的,运用dot net解析XML文件,并在用WinForm进行显示。。。。。
Asp.net读取返回XML页面的信息
根据url,返回xml页面,读取xml页面信息
javabean到XML的转换
NULL 博文链接:https://summerbell.iteye.com/blog/372963


