Yes I copied the script and put in the command input. But now I gave the location for the vb script file like this (cscript\Windows\Temp\Reset.vbs). I am getting an error "The system cannot find the path specified." I also tried like this (\\hostname\cscript\Windows\temp\Reset.vbs)
And also I changed the script like this:
Set objDSE = GetObject("LDAP://rootDSE") strDN = objDSE.Get("defaultNamingContext")
strOU = InputBox("Enter the OU that the user can " & _ "be found in. " & vbCrLf & _ "e.g. OU=dental,OU=students")
If strOU = "" Then WScript.Echo"You have not entered a value in the box. " & vbCrLf & _ "Rerun program if you still want to reset a password" WScript.Quit end if
strCNname = InputBox("Enter the full name (CN name) of the user" & vbCrLf & _ "e.g. Bob Dylan")
if strCNname = "" then WScript.Echo "You have not entered a value in the box. " & vbCrLf & _ "Rerun program if you still want to reset a password" WScript.Quit end if
That is not how cscript works. I'm guessing you have just copied the vbscript from somewhere on the web?
In HPOO using [/lib/operations/remote command/remote command execution] or [/lib/operations/operating systems/windows only/remote command] you will specify the host as the dc to run it on. The startDir will be "c:\temp" or wherever you are storing the script. The command will then be "cscript <scriptName>.vbs".
Alternatively the command could just be "cscript c:\temp\<scriptName>.vbs"
Also looking closer at the script that you've copied, it still won't work in HPOO. It is using InputBoxes to prompt the user to enter details (such as the user to find). You will need to populate all this within HPOO before running the script or pass them as arguments into the vbscript. There are tons of examples of how to do this on google.
Actually I am trying to create a script to ask the user to enter his new password and confirm password. Because, I created a flow which is used to reset user password(which is a random password). But I need the user to enter his own password after he/she enter the random password in his own machine.
Because the enduser doesn't use HP OO. Is there any site to download vb script for HP OO..?