| |
apanian
Posts: 1
Score: 0
Joined: 3/6/2008
Status: offline
|
I have the following script that I obtained from MS script site. My issue is I would like to learn how to build on this script, but lack all the knowledge to do so... Question 1: arrBindings(0).IP = "192.168.1.1" arrBindings(0).Port = "80" arrBindings(0).Hostname = "localhost" THese clearly are parameters for specific fields in the IIS website properties page. There are other properties that I would like to be able to manipulate as well. How do we get this information to know what the "read" check box for the Home Directory" tab is? I just feel like things are kind of "made up" or "declared" but I don't know from whar "root" value/property I hope I've made enough sense to get some replies. thanks in advance. ' Create a New Web Site strComputer = "." Set objWMIService = GetObject _ ("winmgmts:{authenticationLevel=pktPrivacy}\\" _ & strComputer & "\root\microsoftiisv2") Set objWebService = objWMIService.ExecQuery _ ("Select * From IISWebService") arrBindings = Array(0) Set arrBindings(0) = _ objWMIService.Get("ServerBinding").SpawnInstance_() arrBindings(0).IP = "192.168.1.1" arrBindings(0).Port = "80" arrBindings(0).Hostname = "localhost" For Each objItem in objWebService objItem.CreateNewSite "poeticWeb2", arrBindings, _ "c:\inetpub\wwwroot\website" Next
|
|