solomongrundy
IS-IT--Management
Hello all,
I currently have a .vbs script that I use to create user accounts in Active directory. I usually execute 'wscript Script.exe' from the cmd line to execute it. I want to make a webpage that has an 'onClick' event from a button that will execute this action. However, whenever I try to, nothing happens. Can anybody please show me where I am going wrong. Thank you for your time. I am pasting some simple HTML code below:
<html>
<head>
<title>test</title>
</head>
<script language="vbscript">
Public Sub RunScript
Set objShell = CreateObject("WScript.Shell")
objShell.Run = "wscript.exe C:\Scripts\Script.vbs"
End Sub
</script>
<body>
<h1>testing</h1>
<h1>testing things</h1>
<br>
<INPUT TYPE=BUTTON OnClick="RunScript" VALUE="RUN"> text<br>
<br>
</body>
</html>
This HTML file resides in the Scripts folder with the .vbs file.
Thanks,
Solomon
I currently have a .vbs script that I use to create user accounts in Active directory. I usually execute 'wscript Script.exe' from the cmd line to execute it. I want to make a webpage that has an 'onClick' event from a button that will execute this action. However, whenever I try to, nothing happens. Can anybody please show me where I am going wrong. Thank you for your time. I am pasting some simple HTML code below:
<html>
<head>
<title>test</title>
</head>
<script language="vbscript">
Public Sub RunScript
Set objShell = CreateObject("WScript.Shell")
objShell.Run = "wscript.exe C:\Scripts\Script.vbs"
End Sub
</script>
<body>
<h1>testing</h1>
<h1>testing things</h1>
<br>
<INPUT TYPE=BUTTON OnClick="RunScript" VALUE="RUN"> text<br>
<br>
</body>
</html>
This HTML file resides in the Scripts folder with the .vbs file.
Thanks,
Solomon