Allowing teachers to change students passwords
I have a script which will enable a teacher to reset a students password to Password1.
The script works well however i would like it to expire the password, so that the user has to change it to something unique. I have tried asking the teacher to ensure the students change the password, but they do not.
I have tried numerous commands to expire the password, with no luck so it is time i ask the clever people on here for help.
UserDomain = "our_Domain_Name"
UserName = InputBox("Enter the user's login name")
Set User = GetObject("WinNT://"& UserDomain &"/"& UserName &"",user)
NewPassword = "Password1"
If err.number = 0 Then
Wscript.Echo "The password change was successful."
Wscript.Echo "The password change failed!"
Thank you in advance for your help.