Hi, I'm developing a frontend to edit XML documents specified by a Schema. Castor has really made my work a lot easier!
My problem is that during the process of editing or creating an XML document it can be in an invalid state. The frontend allows this to the point of saving the document. When the schema is not followed it is sometimes difficult to realise what is missing / wrong in the XML document. For debugging purposes I would like to inspect the XML by marshalling my Castor object and printing it to System.out. This doesn't work since the current state is not valid and I tried to go around it like this: org.exolab.castor.xml.Marshaller m = new org.exolab.castor.xml.Marshaller(sw); m.setValidation(false); m.marshal(currTxtField, sw); if (!currTxtField.isValid()) System.out.println("This TxtField is not in a valid state!"); System.out.println(sw); I thought that the .setValidation(false) would override any validation but this doesn't seem to be the case. An exception is thrown telling me that this or that field is required. How can I skip validation and still output the XML to a String? Thanks /Emil Breding ----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev