Sorry if this has been asked before or is just plain stupid, I'm new to all this.

After applying a Schema to an XMLDOMDocument40 object, I'm trying to work out which Schema rule has caused a failure. I can tell which element in the XML is wrong and want to use this to et the Schema rule that deals with it. I was under the impression that IXMLDOMNode.definition could do this but I can't for the life of me get it to work.

If anyone could post a short working example, I would be eternally grateful.

I'm using MSXML 4 and VB6.

Thanks in advance,