Dynamic Block Tutorial #5: Controlling Visibility

dynamic block visibility

It’s been a while since I wrote my last dynamic block tutorial. Besides of using parameters and actions, there is one thing left: using visibility states. You can hide and show some (or all) objects and save them on separate visibility state.

Let’s take a dynamic block sample from AutoCAD. I use the trees block. Insert it to your drawing, and click the down arrow in the block. You will see a list of trees. Try to change it to other type of tree.

trees visibility

What it does is hiding objects that form the palm (plan) and show other objects. Let’s try to create our own visibility states.

These doors are actually have a same door type. The only difference is the door on the left can be opened to inside and outside. And the other one can only be opened to one direction.

*What do you call them? single swing and double swing door?

 Dynamic Block Tutorial #5: Controlling Visibility

Create a drawing like the door on the left. Make it as a block. Then open it in block editor. You’ve been doing this several of times, haven’t you? :)

We can’t click any button in visibility panel yet. To enable the visibility states, we need to place visibility parameter first. You can find it in block authoring palette, parameters tab.

visibility parameter

Place it near your block. Pick a good spot, so you and others who will use it can find it easily.

Click the visibility states button. The visibility states dialog box will open.

By default, we will have one visibility state with name VisibilityState0. Select it, and click rename. Rename it to double swing door (or something you prefer).

Click new to create a new visibility state. Give it name single swing door. And make sure you select the leave visibility of existing objects unchanged in new state. Click OK.

new visibility state

AutoCAD will automatically set the new visibility state as current. If the single swing door is not current, select it and click set current. Click OK to close the dialog.

Now we will hide some lines. Activate make invisible from your ribbon.

make invisible

Select all the dashed line that showing the door swing. [enter] to accept.

Click visibility mode to see/hide the invisible lines as opaque lines or hidden. You may want to set it as hidden to see applied changes clearly. But sometimes you need to see the invisible objects when you need to change it to visible.

Test your visibility state. Change it from one to another in visibility state list.

visibility state list

If everything is working fine, you can save the block and close the block editor.

Share This Page


Rate This Page


1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

About the Author

Application Engineer. Jakarta, Indonesia. 5+ years experience as CAD engineering application. AutoCAD, MicroStation, Inventor, Autodesk Revit Architecture 2010 certified professional, and certified CATIA part design specialist. Here are some topics I am currently focusing on

You might also interested to these posts:

  1. Dynamic Block Tutorial #3: 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....
  2. Dynamic Block Tutorial #4: Adding More Actions
    Previously, we have created a door. We add some actions so this door can be resized to an available width in our list. But it’s not perfect yet. At least...
  3. Dynamic Block Tutorial #2: Creating Column
    Let’s continue our dynamic block tutorial. We have created a basic dynamic block tutorial by adding one stretch action to our wall block. We will discuss further about parameter properties...