SQLVDirControl is the only object in the object hierarchy that can be accessed directly using Automation. All other objects are accessed through this object or its derivatives.
SQLVDirControl supports these methods:
Connects to a specific Microsoft® Internet Information Services (IIS) server. The two parameters to this method are: IIS Server name and Web Site number (the number of the Web site in the metabase tree). If none of the parameters is supplied, the local server is the default value for the IIS server, and the first Web site (default Web site) on that IIS server is selected as the default.
Disconnects from the last connected IIS server and the Web site. There are no parameters to this method. You must call Disconnect to close the connection when you are finished or before you connect to another server or Web site.
Note You cannot issue multiple Connect calls to establish connections to many IIS servers. However, if you are trying to connect to the same IIS server but possibly different Web sites, you can call Connect multiple times without calling Disconnect.
The SQLVDirs method retrieves the virtual directory collection of the Web site to which you are connected. After you are connected to a specific IIS server and Web site, call the SQLVDirs to obtain the SQLVDirs collection object, which provides access to the virtual directory objects.
This example shows how to connect to a specific IIS server and Web site on the IIS server. The first Web site is selected on the IIS server.
Set ObjXML = CreateObject("SQLVDir.SQLVDirControl") ObjXML.Connect "IISServer", "1" Set ObjDirs = ObjXML.SQLVDirs ... ObjXML.Disconnect