'documentElement' When I run my site I have this error,why?

Hello Guys

I am having this error when I run my site

 do Microsoft VBScript erro '800a01a8'
Object necessary 'documentElement'

What could it be making this error? Thanks
LVL 1
hidrauAsked:
Who is Participating?
 
sybeCommented:
> I think that my application is not runing the global.asa, is it possible?

Yes, that is possible. The global.asa must be in the root of the application. An application is defined by it's virtual directory. So if you haven't done so, go to the IIS Control Panel and create a virtual directory that points to the root directory of the application.
0
 
sybeCommented:
Are you working with XML? Because that is the only thing I know "documentElement" from.
0
 
hidrauAuthor Commented:
Yeah, I am working with a site where I need to give assistance.

Maybe can it be something wrong in my IIS configuration? Do you know where could I get steps to config my IIS?
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

 
sybeCommented:
Well, the error syas it is a VBScript error. The easiest is to check the code of the ASP script involved. There should also be a line number in the error given.

Post the relevant code here, and we'll see what we can do. I don't think it has anything to do with IIS configuration.
0
 
Carl TawnSystems and Integration DeveloperCommented:
Its sounds like there is a problem loading the XML, so the call to documentElement is invalid.

You need to check your XML source, and that it is valid. If thats ok, you then need to check the XML Dom objects "parseError.reason" property to find out what is wrong with the XML.
0
 
hidrauAuthor Commented:
Below are the lines from my site

Application.Lock
      If Not objSelecionaUsuario Is Nothing Then
             objSelecionaUsuario.setAttribute "url", Request.ServerVariables("url")
      End If
Application("UsuariosLogados") = objXMLUsuario.documentElement.xml
Application.Unlock

0
 
sybeCommented:
Can you show us of which type the variable objSelecionaUsuario is?


Application.Lock
     If Not objSelecionaUsuario Is Nothing Then
          Response.write TypeName(objSelecionaUsuario)
          Response.Flush
          objSelecionaUsuario.setAttribute "url", Request.ServerVariables("url")
     End If
Application("UsuariosLogados") = objXMLUsuario.documentElement.xml
Application.Unlock


0
 
hidrauAuthor Commented:
Sybe, when I inserted your code and run it didn't enter, so I could see that objSelecionaUsuario is nothing, I made some change like this:

      Application.Lock
      If Not objSelecionaUsuario Is Nothing Then
           Response.write TypeName(objSelecionaUsuario)
        Response.Flush
             objSelecionaUsuario.setAttribute "url", Request.ServerVariables("url")
      Else
           Response.write TypeName(objSelecionaUsuario)
        Response.Flush
      End If

It returned me Nothing
0
 
sybeCommented:
So the error is probably on the line

Application("UsuariosLogados") = objXMLUsuario.documentElement.xml

Because a varable of type "Nothing" does not have a property "xml". Of course I don't know how Application("UsuariosLogados") is used in the application, but I'd first just stick it in the "IF" statement.


Application.Lock
     If Not objSelecionaUsuario Is Nothing Then
           objSelecionaUsuario.setAttribute "url", Request.ServerVariables("url")
           Application("UsuariosLogados") = objXMLUsuario.documentElement.xml
     End If
Application.Unlock

If you do this, you might or might not run into problems elsewhere in the application, depending on how Application("UsuariosLogados")  is being used elsewhere.
0
 
sybeCommented:
Of course the best solution is to find out why objSelecionaUsuario is "Nothing". Because something went wrong with loading the XML. Maybe there is an XML file missing somewhere. I get the impression that you copied the code from somewhere and are now trying to make it work. Maybe you did not copy the XML files needed.
0
 
hidrauAuthor Commented:
Is there any way to know the path of my file where my xml is loaded?
0
 
hidrauAuthor Commented:
Well, I am doing some teste and in my global.asa I create a variable this way application("ABC") = '123'

I my file.asp where that code is run, I try to print the contents of variable and nothing, this way:


response.write application("ABC")

I think that my application is not runing the global.asa, is it possible?
0
 
hidrauAuthor Commented:
Yeah, the problem was the global.asa, it wasn't been loaded.

Thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.