Civil 3D – Contour Labels Auto Decimal Place

September 23, 2020 Leo Lavayen

For a long time, with Autodesk Civil 3D I have wanted a smart contour label that drops decimal values.  Something like what is available for Stations, a modifier that could “Drop Decimal Value for Whole”, but none are available by default.

1_Contours

Next, I then turned to Equations and was not able to come up with something simple.  I then found an old post for Crest and Sag Profile Labels, from a colleague James Mussleman.  In the post, equations are leveraged to controls text height.  Below we create a contour label based on the same idea:

  1. First, we will do “Math” to check for the whole number.

2_Contours

  1. Next, an “If” statement is created that will show/hide the right of the decimal. To be used as 2nd Text Height value.

3_Contours

  1. Last, a two-component text label is created:
    • The primary text will always be shown (“Elev-Lt”) with the whole value left of the decimal.
    • 4_Contours
    • The secondary portion of text (“Elev-Rt”) will autohide decimals based on the “If” statement used as height for values right of decimals.
    • 5_Contours

This setup will be useful for situations when contours are set less than whole values or when Surface analysis creates user-defined contours.

6_Contours

7_Contours

 

About the Author

Leo Lavayen

Civil Applications Expert<br><br>As an Applications Expert, Leo is responsible for supporting, training and implementation of software for survey and civil engineering professionals. He has more than 17 years of experience helping large and small, public and private clients in the eastern United States.

More Content by Leo Lavayen
Previous Article
Converting a Civil 3D Pipe Network to an EPA SWMM Model (or vise versa)
Converting a Civil 3D Pipe Network to an EPA SWMM Model (or vise versa)

Currently, there is no way to convert a Pipe Network into a SWMM model without using an intermediary softwa...

Next Article
Identifying an Unknown Source Projection for Spatial Data in Map 3D or Civil 3D
Identifying an Unknown Source Projection for Spatial Data in Map 3D or Civil 3D

Have you ever tried to insert geolocated data or imagery into either AutoCAD Map 3D or Autodesk Civil 3D on...

×

Sign up for email updates

First Name
Last Name
Country
Thank you!
Error - something went wrong!