Hi All,

I realize that this is perhaps not the proper forum to pose this
question, but I am a little stuck.
I am attempting to read a list of xml files from a directory and parse
them. I am able to do this no problem except for when there is a "#" in
the filename (for example: add#1.xml, add#1_Rev2.xml, etc). Does anyone
know a way around this problem?
The code throws a FileNotFoundException when it encounters a filename
with "#" in it.
This seems to be the offending bit of code:

DocumentBuilderFactory docBuilderFactory =
DocumentBuilderFactory.newInstance();
DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
Document doc = docBuilder.parse (new File(xmlFile));

Regards,

Dave

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".

Some relevant archives, FAQs and Forums on JSPs can be found at:

 http://java.sun.com/products/jsp
 http://archives.java.sun.com/jsp-interest.html
 http://forums.java.sun.com
 http://www.jspinsider.com

Reply via email to