F
farseer
Hi,
i am getting an error when trying to deserialize and xml. the error is
shown below. i get this error regardless if i try to desearialize in
C# or VB. the XML itself does infact contain a top level "PDocument"
note which contains an xmlns namespace and some other attriute. is the
error belowing telling it doesn't like that namespace declaration? how
can i programmactically fix this, as i do not have control of the xml i
recieve...i just know that they are valid.
---------------------------------------------
There is an error in XML document (1, 40).
************** Exception Text **************
System.InvalidOperationException: There is an error in XML document (1,
40). ---> System.InvalidOperationException: <PDocument xmlns=''> was
not expected.
at
Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPDocument.Read14_PDocument()
--- End of inner exception stack trace ---
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle, XmlDeserializationEvents events)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader)
...
...{it goes on to show the stack trace here....
...
at Microsoft.Office.Tools.Word.Document.OnStartup()
at ThisDocument.FinishInitialization() in
C:\Proj\Test\MyNote.Designer.vb:line 83
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecutePhase(String
methodName)
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecuteCustomizationStartupCode()
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecuteCustomization(IHostServiceProvider
serviceProvider)
i am getting an error when trying to deserialize and xml. the error is
shown below. i get this error regardless if i try to desearialize in
C# or VB. the XML itself does infact contain a top level "PDocument"
note which contains an xmlns namespace and some other attriute. is the
error belowing telling it doesn't like that namespace declaration? how
can i programmactically fix this, as i do not have control of the xml i
recieve...i just know that they are valid.
---------------------------------------------
There is an error in XML document (1, 40).
************** Exception Text **************
System.InvalidOperationException: There is an error in XML document (1,
40). ---> System.InvalidOperationException: <PDocument xmlns=''> was
not expected.
at
Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPDocument.Read14_PDocument()
--- End of inner exception stack trace ---
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle, XmlDeserializationEvents events)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader, String encodingStyle)
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader
xmlReader)
...
...{it goes on to show the stack trace here....
...
at Microsoft.Office.Tools.Word.Document.OnStartup()
at ThisDocument.FinishInitialization() in
C:\Proj\Test\MyNote.Designer.vb:line 83
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecutePhase(String
methodName)
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecuteCustomizationStartupCode()
at
Microsoft.VisualStudio.Tools.Applications.Runtime.AppDomainManagerInternal.ExecuteCustomization(IHostServiceProvider
serviceProvider)