Home All Groups Group Topic Archive Search About

Getting 80070003: Error connecting to location



Author
12 Dec 2005 9:37 PM
Mike Snetzko
Hi All --

I have a website on an IIS 6.0 server and I am trying to update the settings
via asp page and vbscript.  Below is the code that is supposed to retrieve
the Metapath, and it does, however it is erroring out with 80070003, Can not
find path when I am trying to get connected using the Set IIsWebVirtualDirObj
command.

' Retrieve instance metabase path for root
dim a, a1
a=Request.ServerVariables("INSTANCE_META_PATH")
a1=Mid(""& a &"",4)
Response.Write "<p>" & a1 &"<p>"

On Error Resume Next
dim virtdir
virtdir="IIS://localhost" & a1 & "/"& link &""
Response.Write "<p>"& virtdir &"<p>"
Set IIsWebVirtualDirObj=GetObject(""& virtdir &"")
Response.Write ""& IIsWebVirtualDirObj & "<p>"
If Err <> 0 Then
  Response.Write Hex(Err.Number) & ": " & Err.Description & "<br>"
  Response.Write "Error connecting to location."
End If

Thanks in advance.
Mike

AddThis Social Bookmark Button