<p>I am working on an ASP site hosted using SUN One (used to be called Chillisoft) server. I am having trouble loading in an XML file, the code I am using is below</p>

<pre><code>dim directory
set directory = Server.CreateObject("MSXML2.DOMDocument")

if(directory.load(Server.MapPath("directory.xml"))) then
     Response.Write("Loaded")
else
     Response.Write("NotLoaded")
    If directory.parseError.errorCode Then
        Response.Write( "Parse error" )
    end if
end if
</code></pre>

<p>My asp page and directory.xml are both in the same folder "/public_html/".</p>

<p>I think the problem might have something to do with the mappath not finding the file, but no errors are returned so not sure what to do.</p>

<p>Thanks</p>

I don't know much about Sun One but I do know it has a Bean that emulates MSXML.
Oridinarily, you would use:-
```
```
Set directory = Server.CreateObject("MSXML2.DOMDocument")
directory.async = false
directory.load(Server.MapPath("directory.xml")
```
```
Otherwise load returns immeadiately whilst the xml is loaded asynchronously.
It can't see how the code you have posted would not return something without error.
First diagnositic I would is:-
```
```
Response.Write(Server.MapPath("directory.xml"))
```
```
and then
```
```
Dim direcotory
Set directory = Server.CreateObject("MSXML.DOMDocument")
Response.Write(Not (directory Is Nothing))
```
```