CADTutor: The best free help for AutoCAD on the web
Michael's Corner RSS Feed

Michael’s Corner

Michael BeallMichael's Corner is a monthly publication written by Michael E. Beall, Autodesk Authorized Author and peripatetic AutoCAD trainer. Michael travels all over the USA, bringing his fantastic experience and great understanding of AutoCAD to his clients. Michael's Corner brings together many of the tips, tricks and methods developed during these training sessions for the benefit of all users.

Michael's Corner provides something for every AutoCAD user. Every month, a number of articles cover a wide range of topics, suitable for users at all levels, including "The Basics" for those just starting out. Essentially, the aim of Michael's Corner is to help all AutoCAD users work smarter and faster.


We now have a new system where readers can subscribe (and unsubscribe) to the Michael's Corner mailing list. This is an automatic system which gives you complete control over your subscription. Most importantly, we promise never to share your email details with anyone else.

This month…

October - One-derful!!!

It's a God-thing.

I had no idea that 14 years ago I would be given the opportunity to make an impact on the professional lives of so many. Only God knew what was ahead, and hopefully, the contributions I have made through Michael's Corner have equipped many of you to be more productive and a bit more savvy using AutoCAD. And apart from all the AutoCAD bashing that is going on, I'm sure it has a long life ahead.

So, in an effort to keep the AutoCAD fires burning, here's what I have for my final installment…

…A reminder on how to customize your hot keys
…Three Power Tools — one for Zoom, one for editing, and one for Layers
…Two Odd Spots — one for Layers and one for Hatching
…Buried text treasure
…And how to Search 14 years of the Archives

As for what's ahead for me, I will continue to present a variety of AutoCAD sessions — Fundamentals, Intermediate, Customizing, Updates, and 2D & 3D. I will also keep training CAP Designer, 20-20 Worksheet, Visual Impression (those three from 20-20 Technologies, Inc.), and some Revit Fundamentals. Next year I'm looking forward to being very involved in training CET (from Configura, Inc.) when Herman Miller joins the growing number of manufacturers embracing this software that is being touted as the ‘Future of Space Planning’. Personally, I'm looking forward to spending a bit more time with Donna, my lovely bride of 30 years. When this posts, we'll probably be within days of going on our 30th Anniversary vacation to the Tanque Verde Ranch in Tucson; Ee-Hah! We had such a good time when we went for our 20th, we figured we'd do it again!

Ah, and I'm hoping to have The AutoCAD Workbench, Final Edition out before snow flies.

And with that, Mike drop! …so to speak.

The LORD bless you and keep you;
The LORD make His face shine upon you,
And be gracious to you;
The LORD lift up His countenance upon you,
And give you peace. Numbers 6:24-26

This month's articles

Change F1 to ESC
Smoother Zoom
Stretch with Extension
Lock Layers with a Crossing Window
Layer Columns & Hatch Background Color
Text Frame on Mtext

From the Vault

Originally published February 2014

Running a Script with One Click

Although we covered a lot of customizing ground in my (award-winning!) lab at AU, there was one method I didn't cover, but will definitely have next year: the Script. Several years ago in January 2008, my friend, Lee Ambrosius, stepped in and showed you what scripts can do. Scripts are like a poor man's Lisp, and for a one-liner like me, they're just as effective and much easier to understand.

When to Use What

So what really is "best"? Should you make your own Tab on the Ribbon, put things on the Tool Palette, populate the Quick Access Toolbar, create an Alias? It all depends on how you like to work—and for many of us, it's a combination—but here's my take on those particular customizable components.

Quick Access Toolbar

Quick Access ToolbarOfficially my favorite customization location. You can add single commands, macros, make your own button, run a Script (see below), and it's always visible. I'm a typer, but I love my buttons on the Quick Access Toolbar.


To run a single command by typing, use an alias. For example, I set my system up to use ‘C’ for Copy. No options can be configured when defining an alias; it's just what you want to type to run a singular command.

Tool Palette

Tool PaletteAlthough the QAT is now my favorite, the most powerful customization tool is the Tool Palette, mainly because I can specify the properties—Color, Layer, Style—for the command I'm running, even if that component doesn't exist in the current drawing. Best used when working with drawings from others where you need to be consistent in your standards such as Text style, Dimension style, and Layout tabs.

One-Line Lisp

You can string a command and options into a single one-line Lisp. Once created and added to the Startup Suite (or acaddoc.lsp), it will always be available.

Tab on the Ribbon

Robbon tabProbably the coolest customization for those wanting to click, rather than type, anything you can put on the Quick Access Toolbar, you can put on the Ribbon.

The Script [.SCR]

When you run the .SCR, every line in that file is implemented. For example, you may have a script file that sets up several conditions for the current drawing; the Units, the current Layer, and then Zoom Extents. With a script, it's all or nothing.

By comparison, a .LSP file can contain a single one-line routine that does all those things, but it can also include three separate routines that you can launch one at a time with a simple keystroke.

In the following exercise, you write a script that launches the command line version of the Units command and sets the values to the ones shown in this figure.

Drawing Units

If you would like to configure the values to something other than what is shown here, type -UNITS at the command line and follow the prompts, then use those numbers to replace the ones here.

Also, you may replace the layer being created in the following script—A-FURN—to one that you would like to have in each drawing you work on.

How to Write a Script

  1. Launch Windows Notepad.

  2. Add the lines in red (below) with this understanding:

    * The underscore preceding each line means use the English language version.
    * The hyphen means use the command line version of the command (scripts can't respond to a dialog box).
    * The <SP> means a space goes here; when you hit the spacebar, it's the same as pressing [Enter]

    _-UNITS<SP>4<SP>16<SP>1<SP>0<SP>N<SP> (so this line reads _-UNITS 4 16 1 0 N )
    _-LAYER<SP>MAKE<SP>A-FURN<SP><SP><SP> (yes, three spaces)
    _ZOOM<SP>EXTENTS<SP> …but don't press [Enter] after typing the last space

  3. When you save this file, it must have the extension of .SCR. I named mine, MC_FEB14.SCR, and I would recommend you save it to AutoCAD's ..\Support folder [C:\Program Files\Autodesk\AutoCAD 201x\Support].

Next, we need to put it on the Quick Access Toolbar, so we'll Duplicate the existing ‘Run a Script’ button and edit it to select our Script.

How to Add a Script to the Quick Access Toolbar

  1. Open the CUI.

  2. Expand the Quick Access Toolbars, then Quick Access Toolbar 1.

  3. Under the Command list, navigate to Run Script.

  4. Drag and drop the new commandRight-click on Run Script, then click Duplicate. This is essentially a Copy/Paste routine which retains the integrity of the original command. We will edit the one that has an Element ID with the prefix of ‘MMU’ (before you ask, I have no idea).

  5. Here's what I put in the Properties fields:

    Name Run CAD Tutor Script
    Command Display Name Drawing Setup
    Macro '_script;MC_FEB14
  6. Drag your new command up and release it in the list of commands under Quick Access Toolbar 1.

  7. Click OK to save your edits and close the CUI.

  8. To test your script, begin a new drawing, then set Layer 0 to current and draw a small rectangle.

  9. Click your new Script button. When it's finished, the drawing should have done a Zoom Extents and the layer you put in the 2nd line of the script should be current!

So the next time you open a drawing where the units are not in keeping with what you prefer, or your favorite layer isn't in that drawing, hit your Script button and carry on!

Top of page

Local Navigation

Sponsored Links

Accessibility statement

Valid XHTML 1.0!Valid CSS!Creative Commons Licence