I'm trying to create an alignment label to display profile elevations at regular stations. Two questions:
1. I use an expression to set the text height. When I add a regular text component in the label this works fine, but when I add reference text I can't seem to use the expression as text height.
2. I want to use an expression to 'Truncate' the elevation, so that 178.35m displays as 78.35. I can't find a way to create an expression to do this (within the Alignment station labels).
Thanks for any suggestions.
Mark Green
Working on Civil 3D in Canada
Solved! Go to Solution.
Solved by Jeff_M. Go to Solution.
I attempted your first question myself in Civil 3D 2012 and also found that expressions can't be used to control text height of referenced objects. I'm assuming that due to the variety of objects that you can reference, expressions can't be written to control certain types of objects.
As to your second point, we have a style for top of curb elevations that does exactly what you want, except we truncate down to the ones, not tens. I'd assume your expression would look like:
{Station Value}-100(*TRUNC({Station Value}/100))
Add this to the expressions under Alignments ->Label Styles->Station->Major Station. Format it as a Station, and add it to your label style. You may want to only show the right side of the "+" sign if that's all you want to see.
Thanks!
I'm a little confused about this part:
@Anonymous wrote:....
As to your second point, we have a style for top of curb elevations that does exactly what you want, except we truncate down to the ones, not tens. I'd assume your expression would look like:
{Station Value}-100(*TRUNC({Station Value}/100))
Add this to the expressions under Alignments ->Label Styles->Station->Major Station. Format it as a Station, and add it to your label style. You may want to only show the right side of the "+" sign if that's all you want to see.
Elevation, or Station? I can get Station to work, but it's Elevation I'm looking for.
Mark Green
Working on Civil 3D in Canada
Oh, I'm sorry. I misread your original request. Scratch my last reply. Try this one:
{Profile Elevation}-100*(TRUNC({Profile Elevation}/100))
Add it to your Profile expressions, and add a reference text to your station labels. The only downside is you have to individually select each station (by CTRL-clicking) and tell it the reference object. I don't know of a better way to reference a profile for the entire station label set.
Did that answer your question?
Also, I suppose you could CTRL-click all of the labels in the group and give them all the same object to reference, I just wish you could select the station group itself and add an object as a reference.
Cool, thanks! I had no idea you could put an expression in the profile label family, and refference that expression from the alignment label. I was looking for somewhere in the alignment label to create the expression.
Don't know why it has to be such a pig to use it! The 'Profile Geometry Points' works beautifully—you set the profile right within the alignment labels dialogue. For these ones you have to Ctrl+click, then go to properties. For some reason the properties box doesn't have a pull-down, you have to click on a button, then right-click in the drawing and select from a list. And this is a list of all profiles, not just ones on that alignment! Seriously, I can pull the elevations from one street and display them as alignment labels on a totally different street?
For anyone else reading, the accepted solution is only a solution for my second question. Still wondering about the first.
(I used FLOOR instead of TRUNC. When I was setting up feature line labels the TRUNC didn't work as expected, so I didn't even try it here. FLOOR worked.)
Mark Green
Working on Civil 3D in Canada
I'm looking for a very similar answer to a very similar question and maybe those within this post can help me out. At the very least it will bump this old post up a bit and see if we can't solve the primary question.
As I add labels to my alignments, preferrably with a label tyle - "Station Offset", I was hoping to add ELEV.= ____ to the label style of my "Station offset label style:" However, that isn't available as an option. To summarize I would either like the profile elevation or the the EG surface elevation at the point selected for my Alignment label. Is this possible, and if so what would the expression look like. (Where is the best location to save this expression?)
Thanks in advance.
I can see where you would add profile or elevation data to your label style within the Profile Geometry Points - Alignment labels. That isn't the problem. As you can see by the attached image, is that you can't set these "elevation labels" based on a alignment station interval, nor have them populate for the horizontal geometry points only.
The point is I want the elevations labelled a specific horizontal geometry not vertical geometry. Seems like a simple request, but every angle I've tried thus far isn't opening any doors. Thank you!
In your major/minor label style(s) you can add Reference Text Components which can get data from Profile, Surface, Cogo Point, a different alignment, or parcel. In this case you would use a Surface or Profile. After you add the labels you need to select them (as described earlier in this thread) in order to assign which profile or surface is to be used for the reference text. It cannot be set in the label properties of the Alignment Labels, instead, it is set in the Label Properties on the Properties palette.
Here's a short video demonstrating the process:
And a link to the larger version: https://chronicle.autodesk.com/Main/Details/a7e76d36-0cdd-432c-a87a-9392b134e85e
I found the place that you're speaking and have provided a screenshot of the area where you'd add this reference text to the label style itself. Now when I head to the properties box I don't have an area as to where I would choose this.
Text Component Editor >
EL-<[Profile Elevation(Um|P3|RN|AP|GC|UN|Sn|OF)]>
Anyone show me where I'm supposed to select the profile or surface that would apply?
The key to the story, CTRL+Click on that station label in order to not select the "group" but the label itself, then you property box will give you the "Reference Text Objects" area to select. Huge Thanks for the help!
Joe Bouza
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
Hi @Joe-Bouza looks like I missed your question. Haven't been in this thread since 2012.
@Joe-Bouza wrote:
Hi t
you can get the profile labels and a requested interval, how?
...
I use an expresion to set the text height. This one sets 2mm text height at 15m stations:
IF((FMOD({Station Value}+5,15))!=0,0,.002)
I'm not sure why it wasn't working with the alignment labels of profile elevations. It is now.
Mark Green
Working on Civil 3D in Canada
Mark Green
Working on Civil 3D in Canada
Hello,
How to place alignment lables at an offset from center line of the road with profile elevation expressions
Example,
Finihsed grade = Profile Elavation - (Slope x Offset) ....
FG = 12.50 - (2/100 x OFFSET), WHERE OFFSET IS VARYING
Your help in this regard is highly appreciated
Seasons Greetings
Santhosh