Saturday, March 07, 2015

Revit Family Basics, The Bookcase Example

This article comes from my Revit Basics Blog which I have decided to shut down. It will help the beginner learn about making families by starting with a simple concept and progressively making it harder. It's not a light fixture, air handling unit, or custom sink, but it will put you on the path. Good luck!

In this example a bookcase family is required that a user can define the HxWxD. The number of shelves should be determined by the height, there should also be a control for the thickness of the material and the option to have doors on the bottom 3 shelves.

To gain the type of control needed, the shelves will have to be nested into the bookcase family. Nesting means the shelves will be an independent family that will be loaded into the bookcase family.

Build the Shelf Family

1. Begin with the Generic Model.rft template.

2. Unpin the 2 references planes in the template and uncheck the Defines Origin check box.

3. Add 4 reference planes to define the length and width of the shelf in the reference view. Set the Right and Back reference planes to Define Origin and Pin them in place.

4. Name the new planes (Front, Back, Left, Right) and set the Is Reference parameter accordingly.

5. Use the Extrusion tool on the Home tab to create a form for the shelf, locking it to the 4 defining planes.

6. Use the dimension tool to dimension the Width and depth of the shelf form.

7. Select the width dimension and pick the Label: drop down on the Options Bar, and then select .

8. The Parameter Properties dialog appears. Fill it out as indicated below. Do the same for the Shelf Depth dimension.
9. Switch to the Front view and create a reference plane to define the top of shelf. Name the reference plane, set its reference to Top and lock the top surface of the shelf form to the plane.

10. Set the shelf’s thickness to ½”. Create a parameter for Shelf Thickness as was done with width and depth.

11. Save this family as A-Fn Bookcase-Shelf.rfa

Build the Bookcase Shell

1. Begin with the Generic Model.rft template.

2. Unpin the 2 references planes in the template and uncheck the Defines Origin check box.

3. Add 4 reference planes to define the length and width of the shelf in the reference view. Set the Right and Back reference planes to Define Origin and Pin them in place.

4. Name the new planes (Front, Back, Left, Right) and set the Is Reference parameter accordingly.

5. Add 3 more reference planes to define the thickness of the back and sides of the bookcase.

6. Use the Extrusion and trace the footprint of the bookcase sides and back. Lock the faces of the extrusion to the reference planes.

7. Switch to the Front view and create a reference plane to define the top of bookcase. Name the reference plane, set its reference to Top and lock the top surface of the shelf form to the plane.

8. Create parameters for Bookshelf Height, Bookshelf Width, Bookshelf Depth, and Bookshelf Thickness the same way parameters were added to the shelf family.

9. Add “half” parameters for the bookcase width and depth. These will be used to keep the center planes in the center.

10.  Click the family types button to open its dialog.
11.  Group the “half” parameters under constraints and insert the formulas below to ensure they are always half of their parent lengths.

12.  This is a good time to flex the family by trying different dimensions in the parameters and checking that the geometry follows suit.
Add the Bottom Bookcase Shelf

The intent here is to add one shelf near the bottom of the shell and array it to the top of the shell. We can then create a parameter to determine the number of shelves in the array. That parameter can be driven by an equation that adds more shelves the taller the bookcase gets.

1. Begin loading the shelf family into the bookcase family and place it off to the side in the reference level view of the bookcase family.

2. Use the Align tool to lock the sides of the shelf to the inside planes of the bookcase shell and the front plane.

3. Select the shelf to access its properties. Here we want to create links between the parameters in the shelf to new parameters in the bookcase to control the shelf’s width, depth and thickness.
4. Select the grey box to the right of the Shelf Thickness to add a new parameter. Name it “Shelf Thickness (in case)”, make it an Instance parameter and group it under Constraints.

5. Do the same for Shelf Width and Shelf Depth.

6. In the Family Type dialog we can now create formulas to keep the shelves the correct size as the case changes. Create the formulas shown in the image below.

Creating a Swappable Shelf

To add another level functionality (or complexity) we can add a parameter that will allow the user to switch from one type of shelf to another.

1. Open the original shelf family and save it as the second shelf option. The shelf below has extrusions added to the bottom.

2. Load this new shelf into the bookcase family, but do not place it.

3. In the Family Types dialog create a new Type parameter named “Swappable Shelf”. Make its discipline Common, its Type of Parameter and group it under Constraints.

4. When you select the Type of Parameter Revit will open the Select Category dialog. Pick Generic Models.

5.  Select the original shelf in the bookcase family now. In the Properties dialog, look for the Label parameter and change it to “Swappable Shelf”.

6.  In the Family Types dialog Create 2 shelf types, Shelf Type 1 and Shelf Type 2. Associate the swappable shelf parameter with the appropriate type.

7. Flex the family. Change the family type and verify that the shelf changes.

Array the Shelf

1. Switch to the front view. And move the shelf up 3”. Add a reference plane to the underside of the shelf. Dimension this plane from the reference level and create a parameter named “Bookshelf Toe-Kick”.
2.  Use the Array tool with Group and Associate on and Move To set to “Last”. The array should go from the top of the placed shelf to the top of bookcase reference plane.

3. Select the group and associate line with the current number in the array. On the Options bar select from the label drop down and add a new parameter.

4.  Make it an instance parameter and group it under Constraints.

5. In the Family Types dialog add the equation below to place a shelf at about one shelf per linear foot.

6. Flex the family by changing the height of the bookcase, verifying that the number of shelves changes. Also flex the width, depth, and shelf type.

7. If the shelves lean out of plumb, use the Align tool to lock the upper most shelf in place.

Control the Thickness

For this family the user can input the thickness of the bookshelf, this will in turn drive the thickness of the shelves. Let’s create a formula that allows the user to input any thickness they want, however, if the thickness is less than ½” Revit should use ½” anyway. Conversely if the user specifies any thickness greater than 1”, Revit will use 1” only. If the user specifies any thickness in-between, Revit should consider this a fair value and use it directly.

This requires creating an Actual Thickness parameter and a couple of nested IF statements.

1. Create a new instance parameter and name it Bookshelf Thickness Actual. Group it under Constraints.

2. Apply the following equation to the new parameter.

There are essentially two parts to this nested IF statement.

If (Bookshelf Thickness < 0' 0 1/2", 0' 0 1/2", 

This first part states that if the Bookshelf thickness is less than ½” use ½” for the Actual thickness. If it is not, refer to the rest of the statement.

if (Bookshelf Thickness > 0' 1", 0' 1", Bookshelf Thickness))

The last part states that if the Bookshelf thickness is greater than 1” use 1”. If it is not, use the Bookshelf thickness.

3. To finish apply the Actual thickness parameter to the constraining dimension instead of the nominal one.

if(BCS Thickness < 0' 0 1/2", 0' 0 1/2", if(BCS Thickness > 0' 1 3/4", 0' 1 3/4", BCS Thickness))

Using Model Text to Provide User Feedback

Since the user can specify any thickness they want, even if they are wrong, it may be a good idea to provide feedback to the user if the thickness they provide is out of bounds. Model Text will be used for this.

• Place some Model Text on top off the bookshelf and make the text read "XXX".

• Select the Model Text and pick the little square to the right of the Text Parameter in Properties.

• Add a parameter and name it "Thick Condition"

• In the Family Type dialog and a formula as shown below.

• This formula will test to see if the parameters of Bookcase Thickness and Bookcase Thickness Actual are equal. If so the user supplied good data and the model text should read "GOOD". If they are not equal the users supplied bad data and the model text should read "BAD".

Lastly, we only want the model text to display if the condition is "BAD". To do this, create another parameter Called Thick Condition Visible as shown below.

In the Type Parameters dialog, add this formula to the Thick Condition Visible parameter.

Not (Bookcase Thickness = Bookcase Thickness Actual)

This formula returns a true when model text is in a "BAD" condition. When this yes/no parameter is true, it is visible.

The opposite is when the model text is in a "GOOD" condition, the yes/no parameter is false and the Model text will not display.

Important: You must load this family into a project for this to work. The Good and the BAD are visible in the family, but Only Bad is visible once loaded into a project.

Wednesday, February 25, 2015

Top 20 Revit Tips, Tricks, and Handy Tools

Here are some of my favorite Revit Tips and Tricks.

1)  Previous Selection Set
Ctrl + the left arrow key on your keyboard will re-select the previous selection set.

2)  Filter Selection Sets
Use the Filter tool   to refine selection sets to just the item needed. Combine this with Select all Instances.

3)  Drag to Copy
Hold down the Ctrl key and drag a component to make a copy of it.

4)  Key it In
Tired of the Project Browser and the Properties palettes disappearing? Get them back fast with a couple of custom key-ins.

If custom key-ins made you faster in AutoCAD, consider using the same ones in Revit.  Here are some classic AutoCAD commands and the Revit commands that go with them.
(Break)                        Split Element
(Copy)                         Copy
(Erase)                        Delete
(Fillet)                          Trim/Extend
(Hatch)                        Filled Region
(Insert)                        Link Revit
(Line)                           Detail Line
(Mirror)                        Mirror
(Offset)                        Offset
(Quick Save)                Synchronize
(Trim)                          Trim/Extend
Start by using the keyboard short cut for the keyboard shortcut editor ‘KS’.  

5)  Temporary View Settings
Sometimes you just need to clean up a view to work in it. Enabling temporary view properties allows users aimlessly hack away at visibility graphics with no regrets, because when done, the view properties will return back to standard automatically.

6)  QAT is Whack
It’s there; you might as well use it. Right click on the ribbon to add your most used tools to the QAT. Digging through the ribbon is for losers.

7)  Control the Project Browser
Expand the Project Browser. This is a Windows feature that works in any Explorer-type listing. The Ctrl + asterisk will expand all folders and Ctrl+ - (dash) will collapse them. Be sure to use the keys on the number pad.

8)  Tiny Temporary Dimensions?
Make temporary dimensions size appropriate for mature eyes by selecting Application Menu, then Options, and look in the Graphics tab.

9)  Orient to View
Want to create a 3D view for a specific floor? Right click on view cube, then orient to view, floor plans, and then click on the callout you want to show in your 3D view.

10) Create Identical Dependent Views
If you have dependent views set up for one discipline use the Apply Dependent View tool on the right click menu to apply the same dependent views with the same cropping to other required views for the different disciplines.

11) Create an Image of a View
To create an image of a view, right click on it in the Project Browser, select save as image, then export it from the Application Menu.

12) Transfer Project Standards
Most everything can be swiped from another project rather than recreated.

13) Pick to Delete
Hold down the Delete key and click on items to delete one at a time.

14) Hard Enter
Ctrl + Enter. Use it to force a new line of text instead of waiting for text wrap to work.

15) Drag a View to a New Sheet
In the Project Browser, users can simply drag a view from one sheet to another. No need to delete and replace on a new sheet.

16) SZ
SZ is the same as C for close in AutoCAD.

17) Math Magic in Properties
Place an equal sign in front of any number in the Properties pallet to construct and equation. Click “Apply” to solve.

18) Undo/Redo Drop Down
There is a drop down next to Undo and Redo so you can go to just the right spot.

19) Controlled Zoom
Want to edit text that is really far away and small? Click to edit the text then, hold down the control key and use the mouse wheel to zoom into the text only. It's weird, so you should try it.

20) View Tools
I keyin WT an ZA so much, I think they are my number one used keyins. WT tiles all the open windows, then ZA will zoom all the open windows. Whether I am working on families or projects, I more than not want to see many different view open at once. Nothing helps give me the BIG picture faster than these keyins.

As a bonus, one of the weirdest tools I have ever used is the Replicate view tool. This tool will create a temporary second copy of the active view. The help file indicates that it might be useful if you are working on a close up section and still want to see a far off view. OK. 

I did notice that I could place annotations and lines in either view and they showed in both. The two views have the same name except one is suffixed 1 and the other 2. Close one view and the other reverts back to the original name. You never know when you might to want to replicate a view. 

Seriously, you will never know.

Thursday, February 19, 2015

Revit Type Catalogs

This article comes from my Revit Basics Blog which I have decided to shut down. 

When you have a family that has a lot of options, using a Type Catalog may be the best choice for helping users navigate those options. An obvious example is structural steel. In that case there are many different choices and each choice change the shape, wiegth and identity of the family. Type catalogs use lookup table to look up the appropriate data needed for the different available types.

For this example a dishwasher family is created and it is named dishwasher.rfa.

Select the Family Types button to identify the parameters to associate with the look up table. For this example use Model and Manufacturer. In order for this to work correctly some data has to be placed in Value column. The words model and manufacturer will work, the letter or any other characters will work as well, just don't leave them blank.
Next a look up table needs to be created. I start with an Excel file that will be converted to a TXT file. Save this file with the same exact name as the family. Only the file extension should be different.

Leave cell A1 blank. Revit reconizes this as a heading for Family type which will start below it. Placing any data here will cause things not to work. Fill out the rest of the cells as indicated below.
Column A defines the family Types that can be created.
Column B defines the Model number assigned to that type.
Column C defines the Manufacturer assigned to that type.

The column headers for Model and Manufacturer are a combination of the parameter name to be controlled and a code for the parameter type. The codes are listed below. 
  • Angle                    ##ANGLE##DEGREES
  • Area                     ##AREA##SQUARE_FEET
  • Currency               ##CURRENCY##
  • Integer                 ##OTHER##
  • Length                  ##LENGTH##FEET
  • Material                ##OTHER##
  • Number                ##OTHER##
  • Slope                    ##SLOPE##SLOPE_DEGREES
  • Text                     ##OTHER##
  • Volume                 ##VOLUME##CUBIC_FEET
  • *Yes/No                ##OTHER##
 *When using a Yes/No parameter the Yes=1 and No=0.
When done, save this Excel file with a CSV file type.

Then change it's exrension in Windows Explorer to ".txt".
Test this by loading the dishwasher family into a new project.

Wednesday, February 11, 2015

Browsers on the Right Click

I should be used to little things slipping by unnoticed with Revit by now. Today's discovery, Missing a browser, just right click. There you will find Properties, and now in 2015 you will also find the Project Browser and the System Browser. 

Is it HUGE? Naw, but I like options, and this is a great one.

Friday, February 06, 2015

Radius v. Diameter for MEP Connectors

When placing round connectors in families, Revit allows you drive the dimension of the connector with either the diameter or the radius, but there is a catch.

All of the round connectors must be driven the same way. 

When editing an existing HVAC family to add some hydronic connections, I couldn't change from diameter to radius. A quick test revealed that the round duct connector already set to diameter was locking all round connections to diameter. I deleted the duct connector and the radius choice reappeared.

In this case "all or nothing" set to radius was not a problem, it actually cleaned up the family. It just just a quirk that good to know about. 

Monday, February 02, 2015

Make a Company Logo for a Titleblock

This article comes from my Revit Basics Blog which I have decided to shut down. 

To build a logo for a title block, create a new annotation family. Select the application browser, then New and finally Annotation Family.

Revit offers many templates for annotation families. Revit template families have a RFT file extension. For this example select "Generic Annotation.rft". This template contains two reference planes and a note to the users to specify the type of family. The intersection of the reference planes is the origin for the family. Select the "Category and Parameters" button near the end of the ribbon to change the category. For this example use "Generic Annotation". 

I used text and a filled region to create this logo. 

Now I am going to add a parameter to the text "Omaha" so I can turn it on and off based off which office this logo is attached to. First select the word Omaha. In it's instance properties to the right of the word Visible is a grey box, click it. Now select the Add Parameter button. Name the parameter "Omaha", make it a type parameter and Group it under "Graphics". See below.

Create a Las Vegas Parameter the same way as the Omaha parameter and place the Las Vegas text on top of the Omaha text.

Now let's create two types under this family. One for Omaha and one for Las Vegas. The type will control visibility of the text so only the appropriate city name will appear in each type. Create types by selecting the Family Types button near the end of the ribbon.
On the right-hand side of the Family Types dialog box select New under the family types header. When prompted for a name, type "Omaha". With the Family name set to Omaha, check the Omaha visibility box.
Create and configure a Las Vegas type the same way and load this logo into a project.

Friday, January 30, 2015

Receptacle Family Example

This article comes from my Revit Basics Blog which I have decided to shut down. 

Electrical construction documents depend upon the use of symbolic representations of devices in plan view. The symbolic representation on a receptacle, for example is larger than the actual 3 dimensional modeled receptacle used for elevations and interference detection. It has to be to effectively convey the receptacle type and still be readable at an 1/8th scale. Because it is oversized placing receptacles close together in the model causes the plan symbols to overlap. That is unless the symbolic part of the family can be independently moved from the modeled component. Using a receptacle family as an example, this article will demonstrate how to do just that.

Begin by creating the symbolic annotation family of the plan symbol. Use the generic annotation family template provided with Revit. Name it “Family_A”. Using detail lines draw the plan symbol at the size it would be on a plotted sheet.

Controlling Up and Down Movement

Create another generic family. Use the generic annotation family template again. Name it “Family_AA”. Load “Family_A” into “Family_AA” to create a nested family. Place the nested symbology above the horizontal reference plane in Family_AA, but centered on the vertical plane. Draw a horizontal reference line under the symbology, and make it a weak reference.

Using an aligned dimension or the Align tool, lock the nested receptacle family to the reference line. Add a dimension from the reference line to the horizontal reference plane in “Family_AA”. Add an instance parameter to the dimension and name it “Offset From Wall”. This will add the ability to move the plan symbol away from the hosting wall or entity.

Create a third family using the Generic Face Based or the Generic Model template. Wall based or other options can be used here, so pick what works for to maintain company standards. In any case, the family will be built the same, but “push/pull” options are slightly different once the family is placed into the model. Name the new family “Receptacle”.

Create the following instance Parameters in the new family.

• Offset From Wall

• Offset From Wall2

• Offset L R

Create the following type Parameters in the new family.

• Plan Symbol

• Plan Scale

Load “Family _AA” into the “Receptacle” family and place it on the intersection of the two main reference planes. Assign the “Offset From Wall” in your nested family to the “Offset From Wall2” parameter in the host family by selecting “Family_AA” and selecting the box to the right of the “Offset From Wall” parameter in the Properties palette and then selecting the “Offset From Wall2” parameter in the dialog that pops up. This will allow the user to add a dimension to move the receptacle symbology off the wall without moving the model portion of the family.

Since the receptacle family scale is based on the plan scale, and it is unknown what that scale will be until it is placed in a view, a way push that information to the family is needed. Otherwise, an entered 6” offset may move the receptacle symbol radically more or less than 6” on the plan.  The Plan Scale parameter will be used as a mechanism for the user to convey the view scale to the family. At this time, Revit families do not have a parameter for the scale of the view they are placed in. Click on the Family Types button on the ribbon and as a default, set the “Plan Scale” parameter to 0’-0 1/8”.  To get the proper offset for any scale, add the following formula to the “Offset From Wall2” parameter “Offset From Wall / 1' * Plan Scale”.  The “Plan Scale” parameter must be manually entered by the user.

Controlling Left and Right Movement

To control the side to side movement of the receptacle symbol a vertical reference plane must be dimensioned and labeled. Revit will not allow negative values in dimensions, so the base plane can not be placed in the center of the symbol. To allow the offset to go both left and right of the center reference plane, add a reference plane to the 4’ left of the center reference plane. This sets the maximum offset, so adjust if required. Set the “L R” default to 4’, to align the plan symbol and the elevation symbol when families are placed. This plane should be pinned and set to “Not a Reference”. Create another reference plane and name it “L R”. Lock “Family_AA” to this reference plane, and make it a weak reference. Add a dimension from “L R” to the left reference plane, and set it to “Offset L R”.

If using a face based family, the “push/pull” grips to control the Left and Right location of the symbolic annotation now exist, but the offset from the wall distance must be manually typed in the properties dialog.

If using a generic family, the “push/pull” grips exist for control left and right as well as the offset distance from the wall.

Thursday, January 15, 2015

What Revit Build Number am I on?

Revit is in a constant state of updating. Each update has a build number and it is best practice to keep all of your Revits on the same build. With Autodesk pumping out a build almost every month knowing where your users stand is getting more important. So, how do you know what build a particular computer is on? Look for the question mark in a circle in the upper right-hand corner of your Revit window, click it and select "About Autodesk Revit 2015".

Look in the upper right-hand corner of the dialog that pops up. There is your build number and the equivalent update status.

Older versions of Revit will not provide the update or release translation, just the build number. To figure that out, use the secret decoder below.

First Customer Ship                         Build: 20140223_1515
Update Release 1                            Build: 20140322_1515
Update Release 2                            Build: 20140323_1530
Update Release 3                            Build: 20140606_1530
Update Release 4                            Build: 20140903_1530
Release 2                                      Build: 20140905_0730 (Subscription only release)
Update Release 5                            Build: 20141119_1515
Release 2 Update Release 5              Build: 20141119_0715 (Subscription only release)
Update Release 6                            Build: 20150127_0715
Update Release 7                            Build: 20150303_0715
First Customer Ship                         Build: 201310308_1515
Update Release 1                            Build: 20130709_2115
Update Release 2                            Build: 20131024_2115
Update Release 3                            Build:20140709_2115
First Customer Ship                         Build: 20120221_2030
Update Release 1                            Build: 20120716_1115
Update Release 2                            Build: 20121003_2115
Update Release 3                            Build: 20130531_2115
Revit LT has different build numbers with this release:
First Customer Ship                         Build: 20120821_1330
Update Release 1                            Build: 20130531_0300
First Customer Ship                         Build: 20110309_2315
Update Release 1                            Build: 20110622_0930

Update Release 2                            Build: 20110916_2132

Saturday, January 03, 2015

The Family Man's Family Template

I created my own set of family templates to reduce the steps I always seem to take when making Revit families often on the fly. The process is straight forward and quite helpful.

First start a new family with one of the out of the box templates. I like Generic Model.rft. Now, make tweaks that apply to most every family of this type you like. I typically do the following.

  • Create additional reference planes.
    • I always need them.
    • I name them here to ensure consistent naming convention.
    • I apply the correct "Is Reference" parameter.
    • Reference planes have positive and negative sides. I have OCD, by modeling them in the company template I ensure they are all drawn left to right and bottom to top providing consistent results.

  • Constrain Reference Planes.

    • Again, I always do this. Most every family I make has three basic dimensions. For families placed on ceilings I use Width, Length, and Depth.  For families placed on floors and walls I use Width, Length, and Height.
    • Pre-constraining builds in consistency you will get no other way.

  • Add Solids
    • At this point you might as well add a default solid and lock it to the planes you created.
    • You can also apply default materials if needed.
After completing all the tweaks desired, save the new family as a *.RFA, then in Windows explorer, change the file type to *.RFT. You will get a warning from Windows, just go by it. You now have a Revit family template of your own. Encourage the use your templates by defaulting users to a folder with your standards templates in Options.