M
Morten Nielsen
I'm trying to load an XML file, that references a DTD without a relative
URL. This renders the error: Could not find file
"C:\WINNT\system32\capabilities_1_1_0.dtd".
Here's the XML I'm loading:
http://maps1.intergraph.com/wms/ussample/request.asp?SERVICE=WMS&REQUEST=GetCapabilities
Notice the DTD reference at the second line:
<!DOCTYPE WMT_MS_Capabilities SYSTEM "capabilities_1_1_0.dtd" [
What I try to do:
----------------------------------
WebResponse myResponse = myRequest.GetResponse();
Stream stream = myResponse.GetResponseStream();
XmlDocument doc = new XmlDocument();
doc.Load(stream); // This is where it fails
----------------------------------
The code works fine when no DTD is specified.
Is there some way I can prevent the DTD checking, or make it read the dtd,
which is located relative to the XML file?
Any help is appreciated.
Regards
/Morten Nielsen
Email: http://www.iter.dk/contact.aspx
URL. This renders the error: Could not find file
"C:\WINNT\system32\capabilities_1_1_0.dtd".
Here's the XML I'm loading:
http://maps1.intergraph.com/wms/ussample/request.asp?SERVICE=WMS&REQUEST=GetCapabilities
Notice the DTD reference at the second line:
<!DOCTYPE WMT_MS_Capabilities SYSTEM "capabilities_1_1_0.dtd" [
What I try to do:
----------------------------------
WebResponse myResponse = myRequest.GetResponse();
Stream stream = myResponse.GetResponseStream();
XmlDocument doc = new XmlDocument();
doc.Load(stream); // This is where it fails
----------------------------------
The code works fine when no DTD is specified.
Is there some way I can prevent the DTD checking, or make it read the dtd,
which is located relative to the XML file?
Any help is appreciated.
Regards
/Morten Nielsen
Email: http://www.iter.dk/contact.aspx