Subscribe to Windows IT Pro
December 01, 1998 12:00 AM

ScriptIt

Windows IT Pro
InstantDoc ID #4462
Rating: (6)

Sampling the Power of ScriptIt
Listing 3 is a script that automates creating a new Line Print Remote (LPR) printer port and HP LaserJet 4 Plus shared printer definition on an NT workstation. You can create an LPR port only from the GUI. Listing 3 illustrates many of ScriptIt's features. Although this script appears long and complicated, it performs simple tasks.

Listing 3 contains many REM statements. Adding comments to your scripts always helps other users interpret them. The script includes many examples of ScriptIt's keystroke separator and 5-second delay options. The keystroke separator saves me from repeatedly typing each window title. I use the 5-second delay frequently because without the delay, Listing 3's script processes too quickly for ScriptIt to keep up. I never use the keystroke separator and 5-second delay on the same line so that the window controls can keep up with script processing. Listing 3 uses the mkfile command to create a temporary batch file that echoes the name of the computer the script runs on. Listing 3 then uses the apostrophe to call the batch file to enter the computer name in a dialog box.

To execute this script, which I named addport, I type

scriptit addport

from a command line or Start menu Run command. A ScriptIt icon on the taskbar lets you keep track of the script. You can right-click this icon to terminate your script before it completes. When you terminate a script prematurely, ScriptIt leaves a temporary file in your %temp% directory. To find these files, look for numbered files without extensions. You must delete these files manually.

A Power Tool for Automating That Last 10 Percent
You can script approximately 90 percent of NT configuration tasks from the command line through a combination of built-in commands, resource kit utilities, and third-party scripting tools. The remaining tasks don't have command-line support, so you must perform them from the GUI. ScriptIt is the ideal tool for these kinds of tasks. ScriptIt is also ideal if you're trying to automate an NT installation on hundreds of systems: It lets you script tasks you can't otherwise script (e.g., sound driver installations) so your NT installation is as hands-off as possible. Using NT 4.0's unattended

installation process, you can include a ScriptIt script to install sound drivers during the initial workstation installation using the runonce option. This option prevents you from returning to each workstation and installing sound drivers manually. ScriptIt provides ease of use (no programming is necessary), flexibility, and extensibility. ScriptIt is one of the more interesting tools to come out in a while.

Contact Info
ScriptIt
Microsoft * 800-426-9400
Web: http://www.microsoft.com

WinBatch
Wilson WindowWare * 800-762-8383
Web: http://www.windowware.com

Related Content:

ARTICLE TOOLS

Comments
  • Anonymous User
    7 years ago
    Apr 15, 2005

    I have the same problem with the RunWait command. I copied and pasted the code from the above link and still had the same problem. Do you have to do something with the .dll file? Perhaps put it in the System32 directory?

  • Anonymous User
    8 years ago
    Dec 10, 2004

    look at this page and compare to your script: http://www.dx21.com/SCRIPTING/SCRIPTIT/ViewItem.ASP?OID=101

  • Anonymous User
    8 years ago
    Nov 25, 2004

    RunWait won't work at all for me. All I get is the scriptit window with the title "Scriptit Runwait" and the text "Processing Line: RunWait". That's all. The script never goes any further. I've tried on several machines. I downloaded scriptit again in case it was faulty. RunWait is the command I would use most. Does anyone have any bright ideas. Am I doing something wrong?

  • Anonymous User
    8 years ago
    Oct 27, 2004

    There's an on-line reference for ScriptIt there too -
    http://www.dx21.com/scripting/scriptit/index.asp

  • Anonymous User
    8 years ago
    Oct 27, 2004

    ScriptIt is good, AutoIt is better - much better, free, and actively being developed.

    http://www.Dx21.com/scripting/autoit/index.asp

You must log on before posting a comment.

Are you a new visitor? Register Here

advertisement

advertisement

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.