VbsEdit, the award-winning VBScript editor that dramatically reduces the time you spend writing .VBS scripts

Sample scripts


Terminal Server
   Configuring Terminal Server Properties
       Publish License Server Across Trusted AD Sites , LDAP

' Publish License Server Across Trusted AD Sites



Const ADS_PROPERTY_APPEND = 3 
 
Set objRootDSE = GetObject("LDAP://RootDSE")
strConfigContainer = objRootDSE.Get("configurationNamingContext")

Set objSysInfo = CreateObject("ADSystemInfo")
strSite = objSysInfo.SiteName 
strComputerName = objSysInfo.ComputerName
   
Set adsLS = GetObject("LDAP://CN=TS-Enterprise-License-Server,CN=" & strSite &_ 
",CN=sites," & strConfigContainer)
Set adsContainer = GetObject("LDAP://CN=" & strSite & ",CN=sites," & strConfigContainer)
Set adsLS = adsContainer.Create("LicensingSiteSettings" , "CN=TS-Enterprise-License-Server")

adsLS.PutEx ADS_PROPERTY_APPEND"siteServer"Array(strComputerName)
adsLS.SetInfo



VbsEdit includes all these samples!



Download version 3.4.1
Released Tuesday, January 06, 2009  -   The evaluation version never expires


Home   Buy Now   HtaEdit   Support   Video   What's new ?   Awards

Copyright (C) 2001-2009 Adersoft