XML is not validated when you call the insertXML property in a newly created Office 2003 dcoument (825769)
The information in this article applies to:
- Microsoft Office Professional Edition 2003
- Microsoft Office Word 2003
SYMPTOMSIn Microsoft Office Word 2003 when you insert an XML schema in a newly
created document by calling the InsertXML property, and by using the XML from the current document, the
inserted XML is not validated. CAUSEThis problem occurs because the XML validation is called,
but it quits because the Schema Object Model (SOM) has not yet been validated.
If you call the XMLSchemaReferences.Validate method, the problem is not resolved because this method just
instantiates another validation pass and does not make sure that the SOM has
been validated. WORKAROUNDTo work around this problem, use one of the following
methods. Method 1: Attach the XML Schema Before Calling InsertXMLAlways attach all schemas that are used in the XML that you want
to insert before you call the InsertXML property. Method 2: Validate After You Call the InsertXML PropertyAfter you call the InsertXML property, perform the following two calls to validate the XML: i = ActiveDocument.XMLNodes(1).ChildNodeSuggestions.Count
activedocument.XMLSchemaReferences.Validate STATUSMicrosoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
Modification Type: | Minor | Last Reviewed: | 1/10/2006 |
---|
Keywords: | kbnewfile kbXML kbBug kbpending KB825769 kbAudEndUser |
---|
|