(BTW, I've already looked at the following mail:
http://www.mail-archive.com/dom4j-dev@lists.sourceforge.net/msg00493.html
and it didn't provide sufficient information for what I need.)

Hi. I am currently doing the following:

        Document standingXML =
transformer.parseToStandingXML(generator.getDocument());
        standingXML.addDocType("doc", "", "StandingXML.dtd");

and then:

        boolean validateXML = true;
        SAXReader saxReader = new SAXReader(validateXML);
        saxReader.setIncludeInternalDTDDeclarations(true);
        saxReader.read(docIn);

where "docIn" is "standingXML".

However, I get the following exception:

org.dom4j.DocumentException: null Nested exception: null
      at org.dom4j.io.SAXReader.read(SAXReader.java:342)
      at org.dom4j.io.SAXReader.read(SAXReader.java:256)
Nested exception:
java.net.MalformedURLException
      at java.net.URL.<init>(URL.java:613)
      at java.net.URL.<init>(URL.java:476)
      at java.net.URL.<init>(URL.java:425)

I've already put "StandingXML.dtd" into the location where I am compiling
my class "X" so that it will be picked up, but this does not work.
Any ideas? I am don't think I need to use the EntityResolver interface.


Thanks for your help!
Portia



**********************************************************************************
This email may contain confidential material. If you were not an
intended recipient, please notify the sender and delete all copies.
We may monitor email to and from our network.



-------------------------------------------------------
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

Reply via email to