为什么XmlDocument.LoadXml抛出System.Net.WebException?
发布时间:2020-12-17 00:27:54 所属栏目:大数据 来源:网络整理
导读:为什么System.Xml.XmlDocument.LoadXml方法抛出System.Net.WebException? 这真的是令人难以置信的疯狂,如果MSDN是对的,LoadXml应该最多给我一个System.Xml.XmlException. 但我有奇怪的例外: The underlying connection was closed: The connection was clo
为什么System.Xml.XmlDocument.LoadXml方法抛出System.Net.WebException?
这真的是令人难以置信的疯狂,如果MSDN是对的,LoadXml应该最多给我一个System.Xml.XmlException. 但我有奇怪的例外:
Dim document As New XmlDocument document.LoadXml("<!DOCTYPE html PUBLIC ""-//W3C//DTD XHTML 1.0 Transitional//EN"" ""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd""><x></x>") MsgBox(document.LastChild.Name) 造成异常的是什么?
Edwin给了你解决方案,我给你连接的原因:
http://www.w3.org/blog/systeam/2008/02/08/w3c_s_excessive_dtd_traffic/ (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |