+393713742262
By Assistenza Informatica Firenze/Ottobre 8, 2014/Comments are closed
Recupera gli attributi di un oggetto computer esistente in Active Directory e copia gli attributi su un nuovo oggetto computer (creato dallo script)
[php]
Set objCompt = GetObject("LDAP://cn=Computers,dc=NA,dc=nomepc,dc=com")
Set objComptCopy = objCompt.Create("nomepcnuovo", "cn=dominio01")
objComptCopy.Put "sAMAccountName", "dominio01"
objComptCopy.SetInfo
Set objComptTemplate = GetObject ("LDAP://cn=dominio01,cn=Computers,dc=NA,dc=nomepc,dc=com")
arrAttributes = Array("description", "location")
For Each strAttrib in arrAttributes
strValue = objComptTemplate.Get(strAttrib)
objComptCopy.Put strAttrib, strValue
Next
objComptCopy.SetInfo
[/php]
Copia nome computer in Active Directory, duplica computer Active Directory, Vbs Script Active Directory Computer