So, Friday I was teaching a class on creating styles in Civil 3D. I was showing off how to set up profile vertical curve labels so that when they run off the profile view, they still display correctly. My student asked if it’s possible to have a double arrow when the start or end of the curve is off the profile view. Well, I wasn’t sure how to go about this but, I figured it out. Read on to find out how to do this.

So, in the following image, this is what my student wanted:

On the left, the curve labels start and end outside of the profile view and have a double arrow indicating that there is more outside the view. On the right, the entire labels are in the profile view and therefor display single arrows. How is this done? Well, the key here is expressions. This is a very common tactic for controlling the visibility of label components.

Basically, what we do is create an expression that checks for a certain criteria. If the criteria is met, assign an appropriate height to the object. If the criteria isn’t met, assign a VERY small height to the object that makes it virtually invisible in the drawing.

Here is the expression I used:

The five arrows I’ve put into image point out the five components of the expression.

1) The IF statement is used to test the expression. If you aren’t sure how an IF statement is used, check out the help or the help in Excel, they pretty much work the same way.

2) First part of the test. This is the starting station of the profile curve. What we want to know, is the starting station of the curve, less then…

3) The second part of the test. This is the starting station of the profile view. Basically, if the start station of the curve is less then the start station of the profile view, then the curve starts outside of the profile view.

4) If the test is true (i.e. the curve starts outside the view), then the height of the second arrow is going to be 0.05″ (the /12 part is to convert from feet to inches).

5) If the test is false, then the height of the second arrow is going to be as small as it possibly can. The smallest anything can be in a label style is 0.0004″.

Once the expression is created, I can use it for the height of the second arrow block. I simply copied the first arrow block, assigned an X offset to it, and then changed it’s height to use the expression:

Repeat the process for the end station of the curve.

If you are interested in learning more about expression, check out the class I did for Autodesk University 2009 HERE.