Autodesk Civil 3D: Force slope arrows to point downhill

Autodesk Civil 3D: Force slope arrows to point downhill

When we label a surface with slope arrows in Autodesk Civil 3D (by clicking in the Ribbon -> Annotate Tab -> Labels & Tables panel -> Add Labels dropdown -> Surface -> Slope) we are offered two options (One-point or Two-point):



If you choose one point, the slope label will be always pointing downhill in the direction of maximum slope. However, if you select the two-point option the arrow will point from the first point you click to the second. If the level increases in the direction of the arrow (the arrow points uphill) the value of the slope will be positive. If the arrow points downhill, the value will be negative.

If you have ever taken an Autodesk course on Civil 3D, you are probably familiar with this already. We would like the value to be positive and to indicate the direction of the slope with the arrow, which should always point downhill. Additionally, three decimal places are rarely necessary. One decimal place gives us enough information in most cases. In the following steps, we are going to create a style for the slope label to be displayed in this way.

In order to change the direction of the arrow automatically, we need to create a new expression first. Make sure that Toolspace and the Settings tab are showing by selecting them on the Ribbon -> Home tab -> Palettes panel, as shown below. Then, on Toolspace -> Settings tab, Expand Surface -> Label Styles ->. Slope, right click on Expressions and click on New.

In the window that pops up, give a name to the new expression (we will call it Downhill in our case), optionally add a description, type in the expression IF({Surface Slope} <= 0, 0, pi) and click OK.

Select all the slope labels in the drawing and, on the contextual Ribbon that appears, expand Label Properties and click on Edit Label Style. On the next window, create a copy of the Percent Slope style as shown below.

In the information tab, give the newly created style a name and optionally a description:

Go to the Layout tab and select Slope Text under Component name. When you click on Contents under Text, three dots will appear on that cell. Click on them to continue to the next step.

Firstly, highlight the text on the right by clicking on it. Change the precision to one decimal place and drop the sign to show the value as always positive, as indicated in the screenshot. Please note that you must click on the arrow which points to the right for the changes to take effect. Once you have done that, click OK.

You will get back to the Label Style Composer window. Select Direction Arrow under Component name and click on the dropdown to the right of Rotation Angle. The expression that we created earlier will be available for us to choose. We can select it and click OK. Then click OK again to apply the new style to all your labels, which you had previously selected.

If we have a look at the expression again [IF{Surface Slope}<=0,0,pi)], we can see that it will rotate the arrow pi radians when the surface slope is positive (that is, the arrow points uphill) and leave it unchanged (rotate it 0 radians) when it is already pointing downwards, effectively ending up pointing downhill in any case as we intended. Note: this is only necessary with two-point slope arrows, as one-point arrows always point downwards by default.

The slope labels in our example now display like this:

As a last step, if you wish you can save the drawing as a template so that the style that has been created is available for us to choose in future drawings:

If you want to learn more about Civil 3D, you can have a look at our training courses here.

Blog

Take good care of your emails or risk huge fines

18 January 2021

It seems like such a long time ago that we were all wondering how the General Data Protection Regulation (GDPR) would impact our businesses and it’s easy to imagine that the problem has now gone away, but ignore it, and you could be making an expensive mistake.

Learn more
Blog

Keys, Wallet, Phone – What Have I Forgotten?

15 January 2021

We all have favourite places where we leave them so that we can easily find them later, it may be on a bedside table, in the kitchen draw, a coat pocket, etc. Wherever it is, we know where to start looking, but what about office equipment and assets, where are they?

Learn more
Blog

Starting with an AutoCAD Electrical Project

15 January 2021

In this blog article, we are going to take a deep dive into what an AutoCAD Electrical project is and why it is important to have the correct project setup when starting to use AutoCAD Electrical for the very first time.

Learn more