Hi, is it possible with DOM4j to make/build an XML file from scratch if there is a sequence according to the Schema? Can I insert a tag <location> for example after i added <edition>? How do I know if it will be inserted on the right position? Because if it's not on the good position i will get a sequence error.
<XML> <record> <location>BE</location> ???? <edition>blabla</edition> <location>BE</location> ???? </record> <XML> <XSD> <?xml version="1.0" encoding="UTF-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> <xs:element name="record"> <xs:annotation> <xs:documentation>main element</xs:documentation> </xs:annotation> <xs:complexType> <xs:choice> <xs:element name="book"> <xs:complexType> <xs:sequence> <xs:element name="location"/> <xs:element name="edition"/> <xs:element name="title"/> <xs:element name="author"/> </xs:sequence> </xs:complexType> </xs:element> </xs:choice> </xs:complexType> </xs:element> </xs:schema> <XSD> Can you add elements and let dom4j take care of the good position (with the schema)?? Regards -- Bram ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ dom4j-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dom4j-user