- Remove From My Forums
-
Question
-
While testing if my company should upgrade from Office 2016 -> Office 365, I noticed that an Excel report that works fine with Excel
2010/2013/2016 does not work with Office 365. The report has a connection to an on premise host that serves XML data, we refresh through the Data Ribbon (refresh option).
Upon attempt to refresh in Excel 2016:
Resulting Pop-up:
Import status = Success
Error = Some data was imported as text
Upon refresh on Office 365
Import status = Failed
Error = XML Parse Error
Error Details Pop-up:
Error Code: -1072896682
URL: <not-supplied>
Reason: Invalid at the top level of the document.
Line: 1
Column: 1
File Offset: 0
- Remove From My Forums
-
Question
-
While testing if my company should upgrade from Office 2016 -> Office 365, I noticed that an Excel report that works fine with Excel
2010/2013/2016 does not work with Office 365. The report has a connection to an on premise host that serves XML data, we refresh through the Data Ribbon (refresh option).
Upon attempt to refresh in Excel 2016:
Resulting Pop-up:
Import status = Success
Error = Some data was imported as text
Upon refresh on Office 365
Import status = Failed
Error = XML Parse Error
Error Details Pop-up:
Error Code: -1072896682
URL: <not-supplied>
Reason: Invalid at the top level of the document.
Line: 1
Column: 1
File Offset: 0
I have an XML feed coming in from the outside to post information on my website:
http://secure.pharmacytimes.com/services/Recent_Courses.asp
Now out of nowhere after two months of getting the feed and displaying it properly, I get this error this morning… I saw it working perfectly fine as of last night and didn’t touch anything. Now this morning I am getting this error:
— ErrorCode: -1072896682
ErrorReason: Invalid at the top level of the document.
Here is my code that displays the page:
——————————————————-
<CFHTTP method=»GET» url=»http://secure.pharmacytimes.com/services/Recent_Courses.asp?count=5″ path=»D:InetPubpharmacyweb» file=»pt_ce_recent.xml» timeout=»30″ >
<cfobject action=»CREATE» type=»COM» class=»Microsoft.XMLDOM» name=»objXMLDOM»>
<cfset XMLInputFile = «D:InetPubpharmacywebpt_ce_recent.xml»>
<CFSET objXMLDOM.LOAD(XMLInputFile)>
<CFSET colBookList = objXMLDOM.getElementsByTagName(«course»)>
<!— <TABLE BORDER=»0″ bgcolor=»ffffff» width=»100%»> —>
<TR valign=»top»>
<TD> </TD>
<TD class=»blurbs»><strong>Course Name</strong></TD>
<TD class=»blurbs» align=»center»><strong>Course Units</strong></TD>
<!— <TD class=»blurbs» align=»center»><strong>Course Fee</strong></TD> —>
</TR>
<!— Loop through the collection —>
<CFLOOP COLLECTION=»#colBookList#» Item=»course»>
<CFSET CE_Title = course.SelectSingleNode(«course_name»)>
<CFSET CE_URL = course.SelectSingleNode(«course_url»)>
<CFSET CE_Units = course.SelectSingleNode(«course_units»)>
<CFSET CE_Fee = course.SelectSingleNode(«course_fee»)>
<CFOUTPUT>
<TR valign=»top»>
<TD width=7><IMG alt=* hspace=5 src=»../images/imgArwrt.gif» vspace=5 border=0 width=»7″ height=»7″></A></TD>
<TD class=»blurbs»><a href=»#CE_URL.Text#» target=»_blank»>#CE_Title.Text#</a></TD>
<TD class=»blurbs» align=»center»>#CE_Units.Text#</TD>
<!— <TD class=»blurbs» align=»center»>#LSCurrencyFormat(CE_Fee.Text, «local»)#</TD> —>
</TR>
</CFOUTPUT>
</CFLOOP>
<!— </TABLE> —>
<!—check if an error exists—>
<cfset XMLErr = objXMLDOM.parseError>
<cfoutput>
<cfif XMLErr.errorcode NEQ 0>—
ErrorCode: #XMLErr.errorcode#<br>
ErrorReason: #XMLErr.reason#
</cfif>
</cfoutput>
At work some users are getting an xmlLib Error when trying to run a certain web based database. We used to get it when running Windows XP machines but was able to fix by replacing the later version of msxml3.dll with a newer version containing certain security functions we required. Now with all of the Windows 7 machines the issue has returned but the old fix obviously does not work. At first I thought it may have been because the dllcache folder is no longer called that in Windows 7, which is correct but changing paths to reflect the changes did not fix the issue. I am leaning towards msxml3.dll not being used in Windows 7 and that it must be a newer version, msxml6.dll?? The other reason I want to think this is because awhile back when I original was set to work on this issue, quit because more important things came up, I was reading in the code reference to msxml3.dll but nothing regarding newer versions of this dll. I have also been searching around the net via Google and have not came up with anything close enough to try. Again though I am not very good with XML at all so I may be talking gibberish. Please see below for the error message.
Message from webpage
xmlLib Error: the updateGram response was not
valid xml. Check your document and path. -1072896682 — Invalid at the
top level of the document.
To me, even from my limited XML knowledge, the error appears to showing a invalid connection path to the database.
Does anyone think running a validation on the code could be helpful? I did not write the code nor helped with it so I cannot say if it was done or not.
Я хочу проанализировать и изменить следующий файл .resx с помощью Excel VBA.
.resx в точности такой:
<?xml version = "1.0" encoding = "utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name = "resmimetype">text/microsoft-resx</resheader>
<resheader name = "version">2.0</resheader>
<resheader name = "reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name = "writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name = "Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name = "Color1" type = "System.Drawing.Color, System.Drawing">Blue</data>
<data name = "Bitmap1" mimetype = "application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name = "Icon1" type = "System.Drawing.Icon, System.Drawing" mimetype = "application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id = "root" xmlns = "" xmlns:xsd = "http://www.w3.org/2001/XMLSchema" xmlns:msdata = "urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace = "http://www.w3.org/XML/1998/namespace" />
<xsd:element name = "root" msdata:IsDataSet = "true">
<xsd:complexType>
<xsd:choice maxOccurs = "unbounded">
<xsd:element name = "metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name = "value" type = "xsd:string" minOccurs = "0" />
</xsd:sequence>
<xsd:attribute name = "name" use = "required" type = "xsd:string" />
<xsd:attribute name = "type" type = "xsd:string" />
<xsd:attribute name = "mimetype" type = "xsd:string" />
<xsd:attribute ref = "xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name = "assembly">
<xsd:complexType>
<xsd:attribute name = "alias" type = "xsd:string" />
<xsd:attribute name = "name" type = "xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name = "data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name = "value" type = "xsd:string" minOccurs = "0" msdata:Ordinal = "1" />
<xsd:element name = "comment" type = "xsd:string" minOccurs = "0" msdata:Ordinal = "2" />
</xsd:sequence>
<xsd:attribute name = "name" type = "xsd:string" use = "required" msdata:Ordinal = "1" />
<xsd:attribute name = "type" type = "xsd:string" msdata:Ordinal = "3" />
<xsd:attribute name = "mimetype" type = "xsd:string" msdata:Ordinal = "4" />
<xsd:attribute ref = "xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name = "resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name = "value" type = "xsd:string" minOccurs = "0" msdata:Ordinal = "1" />
</xsd:sequence>
<xsd:attribute name = "name" type = "xsd:string" use = "required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name = "resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name = "version">
<value>2.0</value>
</resheader>
<resheader name = "reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name = "writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name = "Change_phone_number" xml:space = "preserve">
<value>Change phone number</value>
</data>
<data name = "Change_your_mobile_phone_number" xml:space = "preserve">
<value>Please change your mobile phone number</value>
</data>
</root>
Код VBA выглядит так:
Sub ReadXMLDateFromFiles()
Dim ws As Worksheet
Dim XDoc As New MSXML2.DOMDocument
Dim i As Long
Set ws = ThisWorkbook.Sheets("Files")
XDoc.async = False: XDoc.validateOnParse = False
i = 2
Do While ws.Cells(1, i).Value <> ""
XDoc.Load ws.Cells(1, i).Value
XDoc.LoadXML ws.Cells(1, i).Value
Debug.Print XDoc.parseError.reason, XDoc.parseError.ErrorCode
i = i + 1
Loop
Set XDoc = Nothing
End Sub
Как уже упоминалось в заголовке, ошибка:
Error message: Invalid at the top level of the document
Error code: -1072896682
Я не уверен, почему я получаю сообщение об ошибке.
Удаление комментария и тегов <xsd:> тоже не помогает.
Я пробовал код с другими файлами XML, и он работает. Я изменил окончание файла на xml, и он не работает.
Не знаю, что еще попробовать. Файл сохраняется как UTF8. Я могу открыть его в Webstorm без проблем, и он распознается.
XPath, который я бы хотел использовать: XDoc.SelectNodes(«/root/data[@name=’Change_phone_number’]/value»)
У меня в документе в notepad++ начинается следующее начало:
На работе некоторые пользователи получают ошибку xmlLib при попытке запустить определенную веб-базу данных. Раньше мы получали его при работе на компьютерах с Windows XP, но смогли исправить это, заменив более позднюю версию msxml3.dll более новой версией, содержащей определенные необходимые нам функции безопасности. Теперь со всеми машинами с Windows 7 проблема вернулась, но старое исправление явно не работает. Сначала я подумал, что это может быть связано с тем, что папка dllcache больше не называется так в Windows 7, что правильно, но изменение путей для отражения изменений не решило проблему. Я склоняюсь к тому, что msxml3.dll не используется в Windows 7 и что это должна быть более новая версия, msxml6.dll?? Другая причина, по которой я хочу так думать, заключается в том, что некоторое время назад, когда я изначально был настроен на работу над этой проблемой, я ушел, потому что возникли более важные вещи, я читал в ссылке на код msxml3.dll, но ничего не касалось более новых версий этой dll . Я также искал в сети через Google и не нашел ничего достаточно близкого, чтобы попробовать. Опять же, хотя я не очень хорошо разбираюсь в XML, поэтому я могу говорить тарабарщину. Ниже приведено сообщение об ошибке.
Сообщение с веб-страницы
Ошибка xmlLib: ответ updateGram не является допустимым xml. Проверьте документ и путь. -1072896682 — Недействительно на верхнем уровне документа.
Мне, даже из моих ограниченных знаний XML, кажется, что ошибка показывает недопустимый путь подключения к базе данных.
Кто-нибудь думает, что проверка кода может быть полезной? Я не писал код и не помогал с ним, поэтому я не могу сказать, было это сделано или нет.
На работе некоторые пользователи получают ошибку xmlLib при попытке запустить определенную веб-базу данных. Раньше мы получали его при работе на компьютерах с Windows XP, но смогли исправить, заменив более позднюю версию msxml3.dll более новой версией, содержащей определенные функции безопасности, которые нам нужны. Теперь со всеми машинами Windows 7 проблема вернулась, но старое исправление, очевидно, не работает. Сначала я подумал, что это могло быть потому, что папка dllcache больше не называется так в Windows 7, что правильно, но изменение путей для отражения изменений не устранило проблему. Я склоняюсь к тому, что msxml3.dll не используется в Windows 7 и что это должна быть более новая версия, msxml6.dll ?? Другая причина, по которой я хочу думать, это потому, что некоторое время назад, когда я изначально был настроен на работу над этой проблемой, ушел, потому что возникли более важные вещи, я читал ссылку на код на msxml3.dll, но ничего не касалось более новых версий этой dll. . Я также искал в сети через Google и не нашел ничего достаточно близкого, чтобы попробовать. Опять же, хотя я не очень хорошо разбираюсь в XML, поэтому могу говорить чепуху. Пожалуйста, смотрите ниже сообщение об ошибке.
Сообщение с веб-страницы
Ошибка xmlLib: ответ updateGram был недопустимым xml. Проверьте свой документ и путь. -1072896682 — Недействителен на верхнем уровне документа.
На мой взгляд, даже из-за моих ограниченных знаний XML, ошибка показывает неверный путь подключения к базе данных.
Кто-нибудь думает, что проверка кода может быть полезна? Я не писал код и не помогал с ним, поэтому не могу сказать, было это сделано или нет.
1 ответ
Лучший ответ
-1072896682 (XML_E_INVALIDATROOTLEVEL, 0xC00CE556) обычно означает, что обработка DTD запрещена, пока XML содержит его. Вы можете проверить это, отладив код, чтобы проверить, не ProhibitDTD установлен, и XML содержит DTD. Чтобы исправить это, вы можете либо отключить его, либо удалить DTD из XML.
0
Samuel Zhang
12 Июн 2012 в 10:58
I have an XML feed coming in from the outside to post information on my website:
http://secure.pharmacytimes.com/services/Recent_Courses.asp
Now out of nowhere after two months of getting the feed and displaying it properly, I get this error this morning… I saw it working perfectly fine as of last night and didn’t touch anything. Now this morning I am getting this error:
— ErrorCode: -1072896682
ErrorReason: Invalid at the top level of the document.
Here is my code that displays the page:
——————————————————-
<CFHTTP method=»GET» url=»http://secure.pharmacytimes.com/services/Recent_Courses.asp?count=5″ path=»D:InetPubpharmacyweb» file=»pt_ce_recent.xml» timeout=»30″ >
<cfobject action=»CREATE» type=»COM» class=»Microsoft.XMLDOM» name=»objXMLDOM»>
<cfset XMLInputFile = «D:InetPubpharmacywebpt_ce_recent.xml»>
<CFSET objXMLDOM.LOAD(XMLInputFile)>
<CFSET colBookList = objXMLDOM.getElementsByTagName(«course»)>
<!— <TABLE BORDER=»0″ bgcolor=»ffffff» width=»100%»> —>
<TR valign=»top»>
<TD> </TD>
<TD class=»blurbs»><strong>Course Name</strong></TD>
<TD class=»blurbs» align=»center»><strong>Course Units</strong></TD>
<!— <TD class=»blurbs» align=»center»><strong>Course Fee</strong></TD> —>
</TR>
<!— Loop through the collection —>
<CFLOOP COLLECTION=»#colBookList#» Item=»course»>
<CFSET CE_Title = course.SelectSingleNode(«course_name»)>
<CFSET CE_URL = course.SelectSingleNode(«course_url»)>
<CFSET CE_Units = course.SelectSingleNode(«course_units»)>
<CFSET CE_Fee = course.SelectSingleNode(«course_fee»)>
<CFOUTPUT>
<TR valign=»top»>
<TD width=7><IMG alt=* hspace=5 src=»../images/imgArwrt.gif» vspace=5 border=0 width=»7″ height=»7″></A></TD>
<TD class=»blurbs»><a href=»#CE_URL.Text#» target=»_blank»>#CE_Title.Text#</a></TD>
<TD class=»blurbs» align=»center»>#CE_Units.Text#</TD>
<!— <TD class=»blurbs» align=»center»>#LSCurrencyFormat(CE_Fee.Text, «local»)#</TD> —>
</TR>
</CFOUTPUT>
</CFLOOP>
<!— </TABLE> —>
<!—check if an error exists—>
<cfset XMLErr = objXMLDOM.parseError>
<cfoutput>
<cfif XMLErr.errorcode NEQ 0>—
ErrorCode: #XMLErr.errorcode#<br>
ErrorReason: #XMLErr.reason#
</cfif>
</cfoutput>
At work some users are getting an xmlLib Error when trying to run a certain web based database. We used to get it when running Windows XP machines but was able to fix by replacing the later version of msxml3.dll with a newer version containing certain security functions we required. Now with all of the Windows 7 machines the issue has returned but the old fix obviously does not work. At first I thought it may have been because the dllcache folder is no longer called that in Windows 7, which is correct but changing paths to reflect the changes did not fix the issue. I am leaning towards msxml3.dll not being used in Windows 7 and that it must be a newer version, msxml6.dll?? The other reason I want to think this is because awhile back when I original was set to work on this issue, quit because more important things came up, I was reading in the code reference to msxml3.dll but nothing regarding newer versions of this dll. I have also been searching around the net via Google and have not came up with anything close enough to try. Again though I am not very good with XML at all so I may be talking gibberish. Please see below for the error message.
Message from webpage
xmlLib Error: the updateGram response was not
valid xml. Check your document and path. -1072896682 — Invalid at the
top level of the document.
To me, even from my limited XML knowledge, the error appears to showing a invalid connection path to the database.
Does anyone think running a validation on the code could be helpful? I did not write the code nor helped with it so I cannot say if it was done or not.
- Remove From My Forums
-
Question
-
While testing if my company should upgrade from Office 2016 -> Office 365, I noticed that an Excel report that works fine with Excel
2010/2013/2016 does not work with Office 365. The report has a connection to an on premise host that serves XML data, we refresh through the Data Ribbon (refresh option).
Upon attempt to refresh in Excel 2016:
Resulting Pop-up:
Import status = Success
Error = Some data was imported as text
Upon refresh on Office 365
Import status = Failed
Error = XML Parse Error
Error Details Pop-up:
Error Code: -1072896682
URL: <not-supplied>
Reason: Invalid at the top level of the document.
Line: 1
Column: 1
File Offset: 0
xml – Message from webpage xmlLib Error / msxml3 & msxml6
By
March 23, 2022
xml – Message from webpage xmlLib Error / msxml3 & msxml6
-1072896682 (XML_E_INVALIDATROOTLEVEL, 0xC00CE556) normally means that DTD processing is prohibited while the XML contains one. You can verify this by debugging the code to check if ProhibitDTD is set and the XML contains DTD. To fix this, you may either turn it off or remove DTD from XML.
