Launch Application Using JScript

Is there a way to run the application using JScript?

+4
source share
2 answers

You can use something like:

WSH = new ActiveXObject("WScript.Shell"); WSH.run("notepad.exe"); 
+3
source

To run the executable from the Windows Scripting Host using JScript , create a file with the .js extension and add this code:

 var shell = WScript.CreateObject("WScript.Shell"); shell.Run("calc.exe"); 

Double-click the file icon to run and launch the application.

0
source

All Articles