Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to implement getElementById() with Xerces 2.0.1 using XML Schema?

Gerd Rosarius
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey folks,
according to the Xerces API it should be possible to search an entire DOM-Document for an Element with a specific ID using getElementById(String elementId).
I have to declare id-Attributes of my XML Document as id-Attributes by use of a DTD or Schema. XML-Schema is my choice!
With a DTD all works fine, but when I use a XML Schema the method-call getElementById() returns 'null' instead of the expected Element-object.
Any ideas
H.-Gerd Rosarius
[ August 21, 2002: Message edited by: Gerd Rosarius ]
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic