
script error on IADSuser interface
I have a problem running this script, i do not know as to what is the
problem.
Problem: To determine on an NT domain if an NT account is locked or not.
My solution:
Dim obj as IADsUser
Dim username as String
Dim domain as String
domain = "domname"
username = "usrname"
Set obj = GetObject("WinNT://" + domain + "/" + username + ",user")
Dim lockvalue as Boolean
lockvalue = obj.IsAccountLocked
Debug.Print lockvalue
Error i am getting: Line1 char 9 expectedend of statement, ms VBScript
compilation error and errrorcode 800A0401.
my environment: I am running off this a win2k pro station. The domain
controller i will be seeking info from is a win nt 4.0, however i tried
using my local station name and username, and is giving me the same error
request help or a different implementation
Thanks