Exxon_Beta
October 12th, 2005, 01:18 PM
Hi, I'm trying to enumerate the Local Path for every web site I have configured on my 8 web servers. I have looked and looked all over and can't find the Local Path property. here's what I have so far:
-----------------------------------------------------
Dim objW3SVC, objSITE, strServer, TarterUNC
Dim objFSO, objLog
strServer = "LOCALHOST"
TarterUNC = "IIS://" & strServer & "\W3SVC"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objW3SVC = GetObject(TarterUNC)
For Each objSITE In objW3SVC
If objSITE.CLASS = "IIsWebServer" Then
WScript.Echo objSITE.Name
WScript.Echo objSITE.ServerComment
WScript.Echo objSITE.ServerState
WScript.Echo objSITE.DefaultDoc
WScript.Echo objSITE.?????????????
WScript.Echo ""
End If
Next
-----------------------------------------------------------------------
How do I get the Local Path to the web site, such as c:\inetpub\wwwroot
Any help would be greatly appreciated. Thanks.
-----------------------------------------------------
Dim objW3SVC, objSITE, strServer, TarterUNC
Dim objFSO, objLog
strServer = "LOCALHOST"
TarterUNC = "IIS://" & strServer & "\W3SVC"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objW3SVC = GetObject(TarterUNC)
For Each objSITE In objW3SVC
If objSITE.CLASS = "IIsWebServer" Then
WScript.Echo objSITE.Name
WScript.Echo objSITE.ServerComment
WScript.Echo objSITE.ServerState
WScript.Echo objSITE.DefaultDoc
WScript.Echo objSITE.?????????????
WScript.Echo ""
End If
Next
-----------------------------------------------------------------------
How do I get the Local Path to the web site, such as c:\inetpub\wwwroot
Any help would be greatly appreciated. Thanks.