You are browsing the archive for block library.

Preparing Your AutoCAD Template

September 5, 2009 in AutoCAD, CAD, Revit

swirl Using template will increase your productivity. We are not just talking about AutoCAD, but also Revit, Inventor, and any other software like Microsoft Word, Excel, etc. In this tutorial, we are going to prepare our template, save it, and a little configuration to tell AutoCAD to use our template each time we create a new file.


So What is a Template and Why Using It?

Template is a file you use to start a drawing (or any other documents). By default, almost every documentation software provide it. But the default template usually only provide very basic configuration. And mostly don’t meet your criteria.

When you started AutoCAD, by default it will use acad.dwt template. It holds minimum information you need to create a proper drawing. It use inch as units. For me who use metric units, I have to change it to mm. Then I have to do this following things:

  1. Create layers and set their properties.
  2. Create styles for text, dimensions, and other annotation.
  3. Setup my layout for plotting
  4. I don’t usually do this, but I saw some AutoCAD users create block symbols. I prefer to keep them in a block library.
  5. Then I start drawing

Imagine that I have to do that steps each time I start a new drawing. How many hours that I waste in a month? In a year? Wouldn’t it be nice when we start our drawing, we start directly from point no. 5? That’s what a template for. We set our common settings and styles.

Create a new file. Use AutoCAD menu or type NEW [enter]. DO NOT use new icon from quick access toolbar. Using file>new or typing NEW will load a dialog box to select a template. If you use icon from quick access, it won’t open.

Now, because we started using metric, then we use metric template. You can also try to use imperial later.

Preparing Layers

Layers is one of the basic configurations. We will add some layers to this template. Remember the file we created before? The one that contain walls, columns, doors, and centerlines? We will import layers from that file. Check on your layer manager, by default it only contains layer 0. If you see other layers, just remember it.

Open design center. You can click on ribbon>view tab >palettes. Or simply type ADCENTER [enter].

Design center is basically looks like explorer. Find your file. In windows explorer you can expand until file name, but in Design Center, you can see what’s inside an AutoCAD file: layers, dim styles, etc. Click on layers, select all layers you created before. Drag and drop to your drawing area.

design center

Now check in your layer list. Is it already there? :)

Preparing Dimension Styles and Table Styles

I’m not going to write in details how to define a dimension style or table style. If you are new to AutoCAD and interested to know, I can write it in separate post. But I believe many of you who read this already familiar with dimension styles and table styles.

  1. Create a dimension style. We are going to create a plan to be plotted at 1:50 scale. So create a style with name ’1-50 scale’ with arrow size and text height 150, and offset from dimline with 40 unit distance. Create another one with scale 1:100. Give it arrow size and text height 300, and ‘offset from dimline’ with 80. If you have other common scales to use, create it too.
  2. Create a table style for 1:50 scale. Give it text height 150 and margin 50.

Set the new styles for 1:50 for both dimension and table as current.

Preparing Our Layout

The last common setting we are going to set it Layout/Page. You can refer to this post on how to do it. Create several page setup for most common paper size you use. I created 1:50 and 1:100 in this example.

layouts

Save your template. Use save as, then change files of type to ‘AutoCAD Drawing template (*.dwt)’.

saveas

Setting Our Default Template

We are almost done! The last thing we need to setup is telling AutoCAD to use our new template. There are several ways to do this. You have to remember that AutoCAD use default template acad.dwt every time AutoCAD started. You can select default template for QNEW command, but not working if you started AutoCAD. I don’t know if there’s a work around, but honestly I can’t find it. Share it if you know how to do it. So, we can set it by doing this:

Use STARTUP menu:

Set STARTUP system variable to 1. This will load a dialog box that allows you to choose which template you wanted.

file new dialog box

This was a default in older AutoCAD. I don’t know why Autodesk decided to change this sys var to 0 by default. This is a good choice if you have many templates to choose before you started to draw. This work for all version of AutoCAD. Well at least I use it since AutoCAD R.14. I don’t know if they have it in older version.

Alternatively, you can do this to:

AutoCAD 2009 or Older

Backup your acad.dwt. Place the template we’ve created in default template folder,and rename it to acad.dwt.

AutoCAD 2010 or newer

Go to option, user preference tab. Click on Initial Setup button. You will see a wizard that allows you to choose your industry (page 1), your workspace (page 2) and your default template (page 3).

Setup default template for QNEW

The last one, set your default template for QNEW. If you type QNEW or select new from quick access toolbar, this is the template AutoCAD will use. You can find it in option, files tab. It’s under template settings.

default template for QNEW

Now we’re done!

Testing our Template

Try to create a new file, and see your layer list, dimension styles, table styles, and layouts! Try to exit AutoCAD, and see if it also works.




Source: CAD Notes – Preparing Your AutoCAD Template
Go to Source: CAD Notes


Dynamic Block Tutorial #3: Creating Door

August 31, 2009 in AutoCAD, CAD, Revit

red_door This is the last object we are going to create using dynamic block. We are going to create a door. Basically it’s not that different with what we did before. But this time, we are going to learn about action properties. We are going to use wipeout as well.

Now, open your previous tutorial file. We are going to create all of our blocks in a single file. This file will be our block library. Don’t loose it until we finish our tutorial.

Creating the Geometry

Create a new layer: A-Door, with color: blue, and lineweight: 0.09 mm. Set this layer as current layer.

Draw a 50×150 rectangle as the door frame. Copy it to it’s right with 700mm distance. Draw a rectangle 30×650 as door panel. Then draw an arc for swing symbol to complete it.

door geometry

The last thing we are going to add is a wipeout. Activate it, and draw a rectangle wipeout that covers the whole door width.

wipeout

You will see the door frames are covered by the wipeout. Select the wipeout, right click, then from context menu select draw order>send to back.

send to back

Why do we use wipeout? We are going to host our door to a wall. We don’t want to trim or modify our wall after door placement. And modifying the wall length will be reported incorrectly. So we add wipeout to cover our wall later. We will try this at the end :)

Now as usual, create a block from this object. Give it name ‘Single Door’. You can define insertion point wherever you think appropriate. Open your block in block editor.

Adding Parameters and Action

We are still using linear parameter. Add a linear parameter as below.

door parameter

Delete the left arrow. Or you can change ‘number of grips value’ to 1 in properties palette.

There are 3 action we need to add, based to this parameter:

1. Add a stretch action to stretch our door width. Similar to what we do with adding action to wall. This time we only need to create a small rectangle to include the right door frame and the wipeout.

stretch width action

2. Add scale action to resize the arc door swing symbol. This action is very simple to add. Just select the parameter, then select the arc. [ENTER] to finish.

3. Add another stretch action for resizing the door panel. Only select the door panel when this action ask you to select object.

door panel action

Parameter and Action Properties

Placing those action is easy I believe. But we are not finish yet. We are going to limit the door size. We will change some parameter properties just like we did when we create column. Select the parameter. Change the Dist type to ‘List’ and click the … button to input distance value list.

Don’t forget to change this parameter name to something like ‘width’ or ‘door width’.

*You may want to use Increment. But since the last time we used it, I think it will be better to use list now.

parameter value set

Add more values to define your door width.

distance list

The last one, is changing an action properties. Not only parameter has properties! Remember the stretch action for the door panel? Where do you think the door panel will be stretch? Horizontally!

We need to change a property to override this behavior. Select this action, open your palette property. Under overrides category, change the angle offset to 90 degrees.

action overrides

This will override the stretch action, it will stretch the door panel vertically even the parameter is stre
tch horizontally.

Ok, we are done! Save block, and close block editor.

save block

One more thing. We still can see our wipeout frame. Let’s turn it off. Activate wipeout, then type F [ENTER] to activate frame option. Type OFF [ENTER] to turn it off.

Command: WIPEOUT
Specify first point or [Frames/Polyline] <Polyline>: F
Enter mode [ON/OFF] <ON>: OFF
Regenerating model.

Try to stretch your door and don’t forget to try placing your door at walls!

door 

*Notes:

  1. If you can’t see the wipeout covering your wall, select your wall and change the drawing order: send it to back.
  2. You might want to add flip actions so you don’t need to mirror it.




Source: CAD Notes – Dynamic Block Tutorial #3: Creating Door
Go to Source: CAD Notes