I have a shortcut with 'target' "C:\Users\Public\TestPro\TestPro Automation Framework\taf.js".
I want to run that from a batch file so I copied the "C:\Users\Public\TestPro\TestPro Automation Framework\taf.js" into cmd.exe command line and pressed enter. Nothing happened.
How can I run "C:\Users\Public\TestPro\TestPro Automation Framework\taf.js" from a command line on Windows7?
update
the js file contains
var WshShell = new ActiveXObject("Wscript.Shell");
WshShell.run("java -Dlog.dir=%TEMP% -jar taf-loader.jar", 0, false);
WScript.exit;
I tried to run the js file with both Wscript.exe and Cscript.exe as @Serge suggested but nothing worked = the program I start by doubleclicking hasn't started. No error either.
C:\>Cscript.exe "C:\Users\Public\TestPro\TestPro Automation Framework\taf.js"
Microsoft (R) Windows Script Host Version 5.8
Copyright (C) Microsoft Corporation. All rights reserved.
C:\>Wscript.exe "C:\Users\Public\TestPro\TestPro Automation Framework\taf.js"
C:\>