Originally published on: Wed, 09 Dec 2009 19:13:10 +0000
Please note! If you're having difficulties compiling the C source code presented below, please see my post: Compiling C from the Command Line with Pelles C
Several weeks ago, I posted code for a utility that prevents a Windows screen-saver from firing by simulating mouse motion ( http://www.mailsend-online.com/blog?p=47 ).
Today, I'm providing a short WSH JavaScript script that will invoke the default screen-saver. I noted a search for similar functionality that led to my blog. This post will be included in the "By Popular Demand" category of items requested via a search-engine.
runsaver.js
To invoke this script, you may enter one of the two following command-lines:
CScript will run the console version of the WSH interpreter engine; WScript will run the GUI version and will not display a console window.
You may create a shortcut to this script by using wscript.exe as the program to run and runsaver.js as the sole parameter. You might need to specify a full path for the runsaver.js script in the shortcut.
Unless otherwise noted, all code and text entries are Copyright ©2009 by James K. Lawless.
Views expressed in this blog are those of the author and do not necessary reflect those of the author's employer. Views expressed in the comments are those of the responding individual.

Save to StumbleUpon
Digg it
Save to Reddit
Share on Facebook
Share on Twitter
More bookmarks
Click **here**
A JavaScript REPL for Android Devices
A Review of Kevin Mitnick's Book Ghost in the Wires
Play MP3 Files with Python on Windows
Screen Captures with Java and Clojure
Hiding Batch File Console Windows
Thwarting HTTP Referer Trackbacks
Scott Ballantyne: Blazin' Into Forth
An Interview with the Author of the French Silk Assembler
Why Some Web Sites will go Dark on Jan 18th
Book Review : Paull Allen - Idea Man
A 90's Experiment in Online Systems - The U.S. West CommunityLink Service