Civil 3D has not been able to label in consecutive order a polyline with Line and Curve Tags for over a decade now. There are workarounds, but a Dynamo script would probably be better then the best workaround. I do not know how to even start that script. Is the Civil 3D Toolkit needed to see the Line and Curve Tags? Any help would be much appreciated.
Sorry, it don’t know if the counter system has exposed API for dynamo to use, @hosneyalaa ? Just to see the issue i made a polyline and labeled then made a table from the styles used and separate line and curve counters worked fine for me
When labeling a polyline in Civil 3D the Curve Tag increments the Line Tag Number which causes the issue. If you explode the polyline to lines and arcs then the curve tag does not increment the line tag counter and it works. But exploding the polyline is not a good answer for us.
Can the DYN reduce the line tag number by one if a curve was in front of it. Or somehow make it think they are separate lines and arcs not a single polyline.
If it is an Alignment, the Curve Tag does not increment the Line Tag number, it only does it for Polylines.
Would it be easier to renumber the tags with the Dyn, and not create them?
The best workaround, which you may be able to do with a dyn, it to first use Non-Tag labels on all the lines and arcs, and then select them all and change properties to Tag labels. When doing that it seem to number them properly.
You can technically do this using the graph @KirkWM showed above by first creating the labels using non-tag styles and then change the style inputs (the dropdown nodes) after the labels are first created. That essentially does the same thing as updating the styles via the Properties window and will increment the line and curve tag numbers appropriately. However, that is still a bit of a workaround because you’d have to have Dynamo open to be able to run the graph twice and change the inputs between runs. So it wouldn’t work in Dynamo Player.
Assuming that the eventual goal is to have line/curve tables, then another non-Dynamo workaround could be to create the labels using non-tag styles, then add a line/curve table. It will force all of the styles to tag mode and will increment the numbers appropriately.
Could you use Dynamo to create an alignment from the polyline geometry, set the alingment style to be invisible, then add the line/curve tags and tables to the invisible alignment?
However, if the polyline geometry changed, would re-running the graph wipe the original alignment from the drawing or just add another alignment? Maybe its one graph to create the invisble alignment and a second graaph to update the invisible alingment geometry from the selected polyline?
Would it be a big deal to have Dynamo convert your polyline to an alignment that looks like your polyline? Then you can just add the labels and tables in the same graph. Assume you’re labeling only one or two types of lines, it could be easy enough to create a couple new styles to mimic your polyline.
Love learning something new. This seems to be the best work around. I added a label state (just XX) to the Tag labels we need, and when I make the table it automatically switches the state of the labels to the TAG and puts them in consecutive order. Do you want to post this workflow in the Civil 3D forum i put in at the start of this conversation or should I.
It may be a good workaround for some. But since our Line and Curve styles and Table Styles are in a reference template it does not work for us. When you open the dwg the reference template redefines the style which for some reason (BUG) sets the labels back to label instead of TAG, and empties the table. A dyn that found all the labels on the polyline and changed them to a specific TAG only style would still be helpful.