![]() |
| CAD, CAM, CAE, design, technical drawing, drafting, delineation, visualization, manufacturing | ISSN 1442-2255 : 5/11/2008 - 7:03:05 AM |
|
Recording ScriptsIntelliCAD's script file facility allows you to define a sequence of keystrokes in an external file and then run them on command. Script files eliminate the need to repeatedly enter the same series of keystrokes and ensure that exactly the same keystroke sequence is perfomed each time the script is run.Scripts are a great productivity aid and because they simply mimic keyboard entry. If you can perform a sequence of commands from the keyboard, you can define it in a script and repeat it exactly any number of times with perfect accuracy. By incorporating LISP, you can even give scripts some intelligence, but that is another story. Short scripts are easily created just by opening an ASCII text editor (one that does not insert any formatting codes when the file is saved) and typing in the command sequence line by line. Scripts have some (very few) syntax conventions. An "Enter" will be automatically invoked at the end of every line. A ";" character will invoke "Enter" with a line. Save scripts with the .SCR extension. On the other hand, long scripts are nothing but misery to create by directly typing in the command sequence. Scripts tolerate no error and have no debugging facility. Fortunately, IntelliCAD includes a built-in script recorder. You only have to turn it on, draw your way through the sequence you wish to save and turn it off. IntelliCAD can then save that sequence to a SCR file and you can load and run it anytime you like. You can also edit it manually if you want to tweak it a little. At least the bulk of the command sequence can be quickly and accurately saved to file. Recording a Script
Command line entries are recorded verbatim. menu and toolbar selections are recorded as the commands behind these controls. Screen picks in the drawing editor are recorded as 2D coordinate points. There are some "script-specific" commands that can only be invoked from within a script file or which only apply is a script is running.
Running Scripts
Appending ScriptsYou can also append a script you have already created. This is easily done using two instances of your text editor and a quick cut and paste, but IntelliCAD allows you to do it from within as well.
Scripts can be invoked automatically on loading IntelliCAD by double clicking on any script (.SCR) file. Scripts can be easily shared by users and scripts created with IntelliCAD can be used with AutoCAD, provided only AutoCAD-supported commands are used in the recording sequence.
|
|
|||||||||||||||||||||||||||||||||||||||||||||||
| All rights reserved © 1996-2007 Digital Business Media Pty Ltd | home : editorial archive : contact : legal |