O'Reilly logo

Office 2003 XML by Evan Lenz, Mary McRae, Simon St. Laurent

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Appendix D. Using DTDs and RELAX NG Schemas with Office

While Microsoft has chosen to use XSD as the schema language throughout its product line, there are at least two other strong schema languages in regular use today. Both Document Type Definitions (DTDs) and RELAX NG (pronounced “relaxing” but no longer an acronym) are much simpler than XSD, and both offer features that go beyond those in XSD, though in different ways. Developers who need or prefer to integrate DTDs or RELAX NG with Microsoft Office can do so by converting these schemas into XSD with Trang, a very simple but powerful translation tool.

If you need a more detailed explanation of DTDs, any introductory XML book should provide a lot of information. For a more thorough explanation of RELAX NG, see Eric van der Vlist’s RELAX NG (O’Reilly).

XML.com also has a number of excellent articles on RELAX NG and RELAX NG compact syntax that go beyond the coverage in this appendix. To test RELAX NG schemas and perform conversions of either DTDs or RELAX NG schemas into XSD, you’ll want to download James Clark’s Trang package from http://www.thaiopensource.com/relaxng/trang.html. Trang requires that you have a Java runtime installed, but includes all the Java classes it needs in two Java JAR packages.

Tip

If you’re working with existing vocabularies that use DTDs, you’ll definitely need to know how to work with DTDs. Otherwise, if you’re creating new vocabularies, you may want to work with RELAX NG instead.

What Are DTDs?

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required