I am attempting to use the DOMDocument object to create and edit XML files
with inline XDR schemas. Using Microsoft's cryptic documentation, I believe
I have correctly instructed the DOMDocument object to created a valid
sample schema, which produces the following XML output:

<?xml version="1.0"?>
<DocumentContent xmlns:data="x-schema:#InlineSchema">
<Schema name="InlineSchema" xmlns="urn:schemas-microsoft.com:xml-data"

<ElementType name="Hierarchy" minOccurs="1" maxOccurs="1" content="eltOnly">
<element type="TreeNode"/>
<ElementType name="TreeNode" minOccurs="0" maxOccurs="*" content="eltOnly">
<AttributeType name="NodeKey" dt:type="id"/>
<AttributeType name="Caption" dt:type="string"/>
<element type="TreeNode"/>

However, when invoking the Validate method of the DOMDocument object, it
always returns the response: "Validate failed because the root element had
no associated DTD/schema"

Likewise, any methods which rely on explicit data type definitions (such
as nodefromID) also return null results.

Can anyone please explain what I need to do in order to activate the defined
schema? Also, if anyone can suggest a reference source which explains DOM
more clearly than Microsoft's
own documentation, it would be very helpful.

Many thanks for your help
Tim Coulter