Windows Script Host Version 5.8
- Window Script Host Setting
- Open Windows Script Host
- Windows Script Host Version 5.812
- Windows Script Host Version 5.8
- Windows Script Host Download
I have a shortcut with 'target' 'C:UsersPublicTestProTestPro Automation Frameworktaf.js'
.
I want to run that from a batch file so I copied the 'C:UsersPublicTestProTestPro Automation Frameworktaf.js'
into cmd.exe command line and pressed enter. Nothing happened.
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand. No specific info about version 5.8. Please visit the main page of Microsoft ® Windows Script Host on Software Informer.
- 'Microsoft Windows Script Host (WSH) is a language-independent scripting host for Windows Script compatible scripting engines. It brings simple, powerful, and flexible scripting to the Windows 32-bit platform, allowing you to run scripts from both the Windows desktop and the command prompt.
- Windows XP or later Windows: How can I run a batch file in the background with no window displayed? 3 Running cscript.exe from C#.ashx does not execute code in vbscript file.
How can I run 'C:UsersPublicTestProTestPro Automation Frameworktaf.js'
from a command line on Windows7?
update
the js file contains
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.
3 Answers
You have two options:
or
The former one starts the command line version of Windows Scripting Host and the latter one is starting the window version.
The command line options are documented here:https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/cscript
and here:https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/wscript
In your script file you should use the full path to your jar file and possibly full path to the java.exe
Alternatively, to allow the java.exe
locate the tar-loader.jar
file you should change the current directory to the one containing this file, so before invoking wscript
make cd 'C:UsersPublicTestProTestPro Automation Framework'
As you mentioned that you like to run this script in a single touch, you also may create a shortcut on your desktop that has a command line set to Wscript.exe 'C:UsersPublicTestProTestPro Automation Frameworktaf.js'
and working directory set to C:UsersPublicTestProTestPro Automation Framework
• Lifelong unlimited and free of cost conversions. • Enjoy the free music and YouTube song. • No Sign-up or registration required. • Convert and download without additional software installation. Mp3 converter youtube. Youtube Converter Features: • It offers a high-speed conversion and very safe to use.
Need for Speed Hot Pursuit players can also experience the thrill of the chase and the rush of the escape as they play through full careers as both a cop and a racer – solo or connected. The high speed busts and heart-stopping getaways are all connected via Need for Speed Autolog. This file contains the 242 patch data to update your Need for Speed: Hot Pursuit 2 title. See more information for full details included in the patch. EA GAMES(TM) presents. NEED FOR SPEED(TM) HOT PURSUIT 2. PATCH 242 README. WHAT THIS FILE IS ===== This file contains information in regards to Patch 242 for NEED FOR. SPEED(TM) HOT PURSUIT 2. TABLE OF CONTENTS.
If you can run 'java' in a console window with no errors, then
1) Create a text file on your desktop called 'taf.txt'
Window Script Host Setting
2) Enter 'java -Dlog.dir=%TEMP% -jar taf-loader.jar' into the text file, and save it
3) Rename the file to 'taf.bat'
Done.
Open Windows Script Host
Using a scripting host to start a script which launches a shell that launches a java program is just too long winded.
Think of it in terms of what you want to achieve - you want the program to launch with a click of an icon.
The batch file is the fastest way to achieve that on win7.
If you were using an OS that could natively kick off a Javascript script with no messing about it would be a nice way to launch it, but that script wouldn't work on anything other than windows (unless ActiveX is ported now - been a long time since I've used it).
Source: Professional Java Developer for over 10 years
Java 1.6 comes with jrunscript
to run JavaScript outside of web browsers.