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.


What's new in Autodesk Revit 2022.1?

07 October 2021

Autodesk recently released their customary mid release of Revit 2022 with a host of new and useful features for the masses. In this post we shall investigate some of the new and improved features from a structural perspective.

Learn more

Autodesk Fusion 360 Machine Builder and Simulation Preview 

28 September 2021

The machine builder and simulation features in Fusion 360 allow the user to build a machine configuration and 3D machine model adding kinematic movements in preparation for simulation during manufacturing. These features are an essential addition to the prototyping phase of manufacturing, meaning parts can be machined with confidence that minimal restrictions and failures will take place.

Learn more