|
|
|||||||
If you have to access an AD property where the name contains a dash, the solution in vbscript is to surround it with square brackets, but if you try this in KiXtart it will be mistaken for being an array. Could we have ie.: $PrevState = SetOption("IgnoereBrackets","On") Or $PrevState = SetOption("DisableArrays","On") -Erik An examle can be seen here: http://blogs.technet.com/b/heyscriptingg...n-its-name.aspx |
||||||||
|
|
|||||||
While not the solution you are looking for, there is a way to leverage vbscript right in kix... Although I could not completely test this, it should get you in the right direction. You will need GetADUserProperties() to make this work: Code: $User=getaduserproperties() $sc = CreateObject("ScriptControl") $sc.language = "VBScript" $sc.timeout = -1 $sc.addobject('vbuser',$user) $sc.addcode('msds=vbuser.[msDS-User-Account-Control-Computed]') $sc.run ? $sc.codeobject.msds I would be willing to bet there is some other type of AD query that can get this info too. |
||||||||
|
|
|||||||
Also...did you try the method that one of the responses on your link suggests? objUser.Get("msDS-User-Account-Control-Computed") |
||||||||
|
|
|||||||
Shanee I have tried the Get method, it works. But if i try changing the value using the Put method, it fails -Erik |
||||||||
|
|
|||||||
Allen I had not seen your way of calling VBScript before But I managed to solve the problem using the object: ScriptControl Thank You -Erik |