Changes

WPKG with Active Directory

95 bytes added, 17:39, 4 March 2010
Pulling workstation names to hosts.xml from Active Directory OUs automatically with vbScript
Const ADS_SCOPE_SUBTREE = 2
Const VBquot = """"
set fs = CreateObject("Scripting.FileSystemObject")
strOU = ""
textstream.WriteLine vbTab & "<host name=""" & VBquot & objRecordSet.Fields("Name").Value & VBquot & "profile-id="& VBquot & "root" & VBquot & ">"
for each a in arrPath
End If
Next
'Wscript.Echo "Path: " & StrOU strOU = "root" & strOU
arrProfiles=Split(StrOU,"/")
sFullProfile = "root"
iDepth=0
for each sProfile in arrProfiles
iDepth = iDepth + 1 if iDepth > 1 then sFullProfile = sFullProfile & "/" & sProfile textstream.WriteLine vbTab & vbTab & "<profile-id=""" & VBquot & sFullProfile & ""VBquot & " />" end if
next
Anonymous user