Categories

AutoCAD 2012 & AutoCAD LT 2012 Bible

The most comprehensive AutoCAD book around!

AutoCAD 2012 Bible

Defining alternate dimension units in AutoCAD

The dimension measurements in your drawing use a specific unit, whether millimeters, inches, or something else. But it’s common to need to show a second unit — perhaps a metric measurement if you’re using inches, or vice versa.

You define an alternate measurement on the Alternate Units tab of the Dimension Style dialog box. For more information about using this dialog box, see my tutorial, “Create an architectural dimension style.”

AutoCAD Dimension Styles Manager Alternate Units tab

Here are the steps to specify an alternate unit:

  1. Choose the unit you want from the Unit Format drop-down list.
  2. Choose the precision (decimal points or fraction denominator, usually)
  3. Notice the default 25.4 in the Multiplier for All Units text box. That’s because I have a United States version of AutoCAD and there are 25.4 millimeters in an inch. Of course, if that’s not what you want, change the multiplier value.
  4. There are text boxes to add a prefix or suffix. These are useful if the unit won’t be obvious. For example, if you main units are inches, you might want to add mm after your alternate units of milliemeters.
  5. The Zero Suppression section of the dialog box allows you to keep certain standards, such as not including 0 inches before (leading) or after (trailing) a measurement.
  6. Finally, on the right, specify if you want the alternate to appear after or below the primary measurement.

The settings you specify become part of the dimension style you are configuring.

Do you use this feature? What settings do you use?

Draw a circle centered in a rectangle

It’s common to need to place a circle in the middle of a rectangle, especially in mechanical drawings. It’s easy to do using object snap tracking.

Object snap tracking tracks the coordinates on object snaps and for this task, you need to track the midpoint of the rectangle’s sides. Here are the steps:

  1. Make sure that the Object Snap Tracking button on the status bar is on, or press F11.
  2. Make sure the midpoint object snap is on or press F3.
  3. Right-click the Object Snap button on the status bar and choose Midpoint, if it isn’t already highlighted.  This sets a running object snap for midpoints.
  4. Draw a rectangle (RECTANG command).
  5. Start the CIRCLE command.
  6. At the Specify center point for circle or [3P/2P/Ttr (tan tan radius)]: prompt, pass the cursor over one midpoint of a rectangle side until you see it marked. This is called acquiring the object snap.
  7. Move the cursor toward the center of the rectangle and then pass the cursor over a rectangle side that is perpendicular to the first side, to acquire that sides midpoint.
  8. Move the cursor toward the center of the rectangle until you see the tracking lines from both midpoints cross each other at the rectangle’s center.
  9. Click to specify the circle’s center.
  10. At the Specify radius of circle or [Diameter]:  prompt, specify the circle’s radius.

Watch the video to see how it’s done!

 

How do you use object snap tracking?

Open AutoCAD with a specific template

autocad-tips-start-templateYou can launch AutoCAD with a specific template of your choice. You do this with a command line switch.

When you double-click the icon on your desktop or start AutoCAD from the Start menu, you are executing a statement. You can customize this statement by adding parameters, also called switches.

To learn the statement of your desktop icon, right-click it and choose Properties. On the Shortcut tab, look in the Target text box. This is also where you add a switch. For example, the statement might look like this:

“C:\Program Files\Autodesk\AutoCAD 2012\acad.exe”

To add a switch insert a space after the end of the statement and add a forward slash (/), then the switch you want. (AutoCAD has a number of switches, not just for templates.) In most cases you also add a descriptor.

For a template named mytemplate, you would add /t mytemplate. The statement for the Tutorial-iArch template would then look like this:

“C:\Program Files\Autodesk\AutoCAD 2012\acad.exe” /t Tutorial-iArch

Note: You need to add quotation marks around any path or name (such as the template name) that contains spaces.

I recommend duplicating the existing shortcut. When you use this method, you can create different shortcuts for different templates. To change the command line switch, follow these steps:

  1. Right-click the shortcut and choose Copy.
  2. Right-click the desktop and choose Paste. You’ll either get a new shortcut with “Copy” appended to the name or a dialog box that gives you the option to keep both the original and the copy with a number appended to the name. You can change the name of the shortcut to reflect the name of the template it will open.
  3. Right-click the shortcut copy and choose Properties.
  4. On the Shortcut tab, in the Target text box (not the Start In box), move the cursor to the end of the existing statement.
  5. Press the spacebar to add a space, then type /t and another space. Finally add the name of the template. Be sure to add quotation marks around the template name if it contains spaces.
  6. Click OK.

Try out your new shortcut by double-clicking it!

Did you find this helpful? Do you use switches? How?

Happy New Year!

For those of you who celebrate holidays at this time of year, I want to wish you a happy holiday season. For everyone, a happy New Year.

 

Close AutoCAD quickly and safely — and get home earlier!

Just in time for the holidays, when you may want to rush out the door, here is a guest blog post from . Your family will thank you!

AutoCAD tips: Close AutoCAD quickly and safelyWe’ve all done it. You are beavering away at the office, totally engrossed in the Music on your iPod in your work, when you realize that it was time to go home minutes ago!

I want to make sure that you know about 3 really handy commands that will help you to close down a lot of open files very quickly (and safely).

Save everything

The first command is an Express tool called SAVEALL. Simply type saveall at the command line, and all your open drawings will be saved, but remain open.

Close everything

The second command is a standard AutoCAD command called CLOSEALL. Once again, simply type closeall at the command line, and all your drawings will be closed Lickety Split.

Or do both

The final command is another Express tool called QQUIT. This tool will attempt to save and close all your drawings, and then close AutoCAD down completely.

Note: If a drawing has not been saved yet, all of these commands will prompt for a file name. If you have a blank drawing file open that you don’t need to save – just hit ‘Cancel’, AutoCAD will still process the rest of the files.

Go Home

Don’t stop to thank me – have a great evening!

  is the writer of The CAD Setter Out, supplying tips, tricks and tutorials for Drafters using AutoCAD and Autodesk Inventor to create drawings for the construction industry. In his spare time Paul enjoys Drawing and Woodworking. He thinks that modelling his Joinery designs in 3D is the most fun anyone can have, by themselves…

Get rid of the default grid in AutoCAD

Starting with AutoCAD 2011, Autodesk has made the grid on by default. Do you turn it off every time you start AutoCAD?

If you don’t know how to turn it off permanently, here are the steps:

  1. Open the template you usually use. If you use the default, acad.dwt, open that. The location will depend on your release and version of Windows. You might have to search for it in Windows Explorer, because the folder path is very long! When you find it, you can double-click it to open it. If you’re navigating from within AutoCAD, be sure to choose Drawing Template (*.dwt) from the Files of Type drop-down in the Select File dialog box.

  1. Click the Grid Display button on the status bar or press F7.
  2. Save the template.

Now, when you open AutoCAD, the grid is gone!

 

Make the command line work the way you want it to

The command line is an essential component of drawing in AutoCAD. Even if you don’t type comments there, you need to look at it for prompts and you probably use it to specify options.

The command line is actually a palette window. By default, the command line is docked at the bottom of your screen.

AutoCAD tips: Command line

See more of the command line

Another default is that the command line palette shows 3 lines of text: the Command: prompt and 2 previous lines. You can drag the upper edge of the palette to show more lines.

AutoCAD tips: Command line

To display the entire history of the command line, press F2 to open the AutoCAD Text Window.

AutoCAD tips: Command line

See less of the command line

On the other hand, if you think that the command line takes up too much space you can hide it or collapse it.

To hide the command line, pres CTrl + 9. So you don’t do this by accident without knowing how to get the command line back, you see this message:

AutoCAD tips: Command line

Check the Always Close the Command Line Window check box to avoid seeing this message the next time. Then click Yes. Now, you can easily toggle the command line to display and hide it.

To collapse the command line (like other palettes such as the Properties window or the Tool Palettes), first undock it by dragging its gray title bar at the left.

AutoCAD tips: Command line

Then right-click the gray title bar and choose Auto-Hide. The command line palette collapses to a small gray bar. That’s pretty small! But as soon as you hover your cursor over the bar, the command line expands.

AutoCAD tips: Command line

Let AutoCAD help you

Starting with AutoCAD 2012, when you start to type a command, AutoCAD auto-completes. If you pause, you see all commands starting with the letters you typed and you can choose the desired command.

AutoCAD tips: Command line

You can do minor editing as you type, in case you make a mistake (before pressing Enter):

  • Home: Moves the cursor to the beginning of the line
  • End: Moves the cursor to the end of the line
  • Left arrow: Moves the cursor to the left
  • Right arrow: Moves the cursor to the right
  • Backspace: Deletes the character to the left of the cursor
  • Delete: Deletes the character to the right of the cursor

You can also use Ctrl+V to paste text from the Windows clipboard.

More command line tricks & tips

Here are some more ways to make using the command line easier:

  • Repeat the last line you entered: Press the Up arrow and pres Enter.
  • Copy a previous command from the Text Window: Press F2 to open the Text Window, highlight the item you want, right-click, and choose Paste To CmdLine.
  • Repeat a recent command: In the Text Windows, right-click and choose Recent Commands. Then choose the command you want.

Do you have any tips for using the command line window? Leave a comment!

Make hatching in AutoCAD easy

Hatching can sometimes be frustrating, so I’ve collected a few hatching tips together, including links to other tips. Think of the collection as your personal hatching helper.

In case you don’t know, a hatch is a pattern of lines and dots that fills an enclosed area.

AutoCAD tips-easy hatching

Create user-defined hatch patterns

When you choose a hatch pattern and apply it, it doesn’t always look the way you want it to. You can try to find a better hatch pattern, but an easy way to deal with this problem is to create a user-defined hatch pattern. A user-defined hatch pattern just lets you specify the angle of the pattern and its scale. Changing the scale is an especially easy way to correct a hatch pattern whose spacing is too close or too wide.

Increasing the scale makes the spacing wider; decreasing the scale makes the spacing closer (narrower). A value of 1 is the default, so to make the lines closer together, use a value that is between 0 and 1.

AutoCAD tips-easy hatching

Start the HATCH command

Before you start hatching, you might want to create a separate layer for the hatch and make it current. When you start the HATCH command (Home tab> Draw panel> Hatch), the Hatch Creation tab appears. Choose the pattern you want from the Pattern panel.

At the Pick internal point or [Select objects/seTtings]: prompt, click inside the closed area or use the Select objects option. An easy way to switch between picking internal points and selecting objects is to right click and choose the option that isn’t current from the shortcut menu. In this example, you would choose Select Objects.

AutoCAD tips-easy hatching

For more information, see the older (but updated) tip, “Easy hatching.”

Define the enclosed area properly

Sometimes, AutoCAD won’t hatch the right area. Here are some hints for defining the enclosed area:

Franck Wallez advises drawing with polylines, instead of with lines. One reason is that they make specifying an enclosed area easier. If your enclosed area is complex, use the BOUNDARY or REGION commands to create a closed area.

If you’re enclosed area has gaps, AutoCAD has a solution. See my tip, “Dealing with gaps.”

Customize your hatches

A user-defined hatch may not give you enough flexibility. In that case, you can build your own hatch patterns. See “Creating custom hatch patterns” for the details.

A minor customization is to specify the hatch origin. For example, if you’re filling in a wall with a brick hatch, you may want the brick pattern to start at the lower-left corner.  See the tip, “Control hatch origin.”

Another minor customization is to control islands, which are embedded shapes. See the tip, “Manage embedded shapes (islands) when hatching in AutoCAD” for more information.

What about paper space?

When you display your hatches in paper space, you may be in for a rude surprise.Your hatches in scaled viewports no longer have the right spacing! The solution is to make your hatches annotative. To do so, click the Annotative button in the  Hatch Creation tab’s Options panel.

For a tutorial on annotative objects, see “Tutorial: Automate annotation scaling with annotative objects.”

Use this secret for easy selection of hatched objects

It can be difficult to select hatched objects, because there are so many hatch lines nearby. Franck Wallez recommends the HATCHTOBACK command, which  moves all your hatching under everything else. Then, clicking on the hatched object is more likely to select the object you want and not the hatch.

Do you have any hatch tips? Please leave a comment and share them!

Done in AutoCAD 2012

Fillets–another approach using AutoLISP

Tommy Holder submitted a different approach to creating fillets–one that includes drawing the lines. For the earlier routine, see “Reduce mouse clicks and increase productivity with AutoLISP.”

Tommy’s approach is unique, I think. Instead of drawing the lines first, the AutoLISP routine prompts you for points, which are the endpoints of the lines. Here are the steps:

  1. Download fl.lsp. FL.lsp (click to download)
  2. Unzip the file.
  3. Use the APPLOAD command to load fl.lsp in a location that is in AutoCAD’s support file search path.
  4. On the command line, type fl and press Enter.
  5. At the Enter points : prompt, specify the first line’s start point.
  6. The prompt repeats, so specify the first line’s end point (which is also the second line’s start point)
  7. Next, specify the second line’s endpoint and press Enter.
  8. At the Enter BEND RADIUS <1.0000>: prompt, enter the fillet radius and press Enter.

Watch the video!

Tommy Holder has 35 years experience with Ingalls Shipbuilding on the Mississippi Gulf Coast where the company has built numerous ships for the Navy. He has been a CAD designer and developer, having written many lines of code, developed many menus, and trained many users. He has been a project lead and supervisor but found that his true calling was not in management but CAD development and helping users.

Tutorial: Create cool curves with splines in AutoCAD

Splines are mathematically-defined curves. They are an important basis for 3D modeling, but they are useful in 2D as well.

Note: Splines were significantly updated in AutoCAD 2011.

There are 2 methods for creating splines:

  • Fit Points: You specify fit points, which are on the spline (by default).
  • Control Points: You specify the control points, which usually are not on the spline itself. Useful as a basis for 3D NURBS surfaces.

I’ll give you the prompts for the Fit Points method.

Start the SPLINE command. You see the method listed on the command line, as shown here. If the method if not set to Fit, use the Method option to change it.

Like this:

Current settings: Method=Fit   Knots=Chord

or like this:

Current settings: Method=Fit   Knots=Chord
Specify first point or [Method/Knots/Object]: _M
Enter spline creation method [Fit/CV] <Fit>: _FIT
Current settings: Method=Fit   Knots=Chord

  1. At the Specify first point or [Method/Knots/Object]: prompt, specify the first point for the spline.
  2. At the Enter next point or [start Tangency/toLerance]: prompt, specify the next point. You can use the start Tangency option to specify the direction of the start of the spline. You do this by picking a point off the start point of the spline.
  3. At the Enter next point or [end Tangency/toLerance/Undo]: prompt, specify the next point or use the Close option to create a closed spline. At the 3rd and subsequent prompts, you can similarly use the end Tangency option to specify the direction of the end of the spline. The toLerance option lets you give the spline latitude, in units, from being exactly on the fit points that you specify. The default value, 0, puts the spline exactly on the fit points.
  4. Continue to specify points until your spline is done.
  5. Press Enter to end the SPLINE command.

AutoCAD tips: Draw cool curves with splines

Done in AutoCAD 2012