Multiple corridor creation using dynamo


I am currently working on a site development which consist of more than 40 roads. We have just migrated to civil3d2021 and i am fascinated about using Dynamo especially for redundant task.

Normally our process are;

  1. Create existing ground surface file using survey data
  2. Create Data shortcut for the existing ground
  3. Data reference the existing ground and create the alignment, profile-views and design profiles in a separate file.
  4. Create Data shortcut for the alignment/profile.
  5. Create a file where we data-shortcut all the data required.
  6. Create corridor and surface (In step 6 we normally create separate corridors to each alignment due to file size and sometimes we divided the site and create multiple corridor files).

This is a tedious job and we spent several weeks to finish. Now, we were awarded a site which may consist of more than 200 alignments. However, the timeline is very tight which could also take effect in our ongoing projects.

I am hoping somebody could assist me on how to reduce our process especially step 3 and 6 that would be a HUGE help for us.


Hi @Ernest.Villanueva,

I have not tried something like this, but the Civil3DToolkit Package has a lot of nodes which will probably help you out a lot!

Very good question, I would like to know the answer as well, I have same situation as well.

Hi @Ernest.Villanueva,

Not an expert but i can suggest a way for step 3.

If you have polylines for all your alignment then you can create a graph and convert all polylines in to alignment just in a click. Had recently tested creating alignment from polyline and it worked for a group of selection.

on the same concept if you can create profile views too.

For design profile you need elevations and stations. if you have that then you can create design profile too.

Hope this helps.

1 Like

Hello again, is there any script to create a corridor from a file which have all the alignments and profiles?

Hi @Ernest.Villanueva,

There are a lot of steps involved in this post, so I will make some other posts separately to split this up. I’ll post the links below.

This is not currently possible because there are no public methods exposed in the Civil 3D API for working with data shortcuts. The same answer applies to steps 4 and 5.

Here is an example I put together for you that shows how to create multiple corridors in a single file. I used an Excel file to drive some of the inputs, but that approach is just for illustrative purposes. Creating the corridors and settings various parameters can be done a combination of OOTB nodes and the Civil 3D Toolkit package, but creating the surfaces requires a Python solution at the moment. The code I wrote will (1) add a surface to each corridor, (2) add whichever links you want (I just used the Top links), and (3) add the corridor extents as a boundary. Here is the dataset - hope it helps!

CreateCorridors.dwg (981.0 KB)
CreateCorridors.dyn (89.7 KB)
MultipleCorridors.xlsx (8.8 KB)


Hello, I have this question on corridor surfaces and boundary. Civil 3D Toolkit Feedback thread - #719 by Drbohlav Do you know about any solution or have any tip?

@Ernest.Villanueva - see this post:

@Ernest.Villanueva see post here for creating EG surface profiles:

Can you open a new post?

1 Like

Here is new post Add boundary to corridor surface

@Ernest.Villanueva - see this post.

@Ernest.Villanueva - see this post:

@Ernest.Villanueva - see this post:

Thank you so much on sharing some of the dynamo scripts. i tried running it in my work and it works! i made some iteration on targeting the surface and it works perfectly. the only thing i need to create are the intersections.

Once again thank you for your support!


Silly question, but can you tell me how you get that “name” variable input onto that code block?

Never mind, I believe I found what I was missing in the Primer. Thanks!

I was also wondering about these to nodes:

Are the Object.Identity nodes basically just allowing you to make a cleaner-looking diagram (very clever idea btw)? Or is there something else more subtle that I’m missing?
And are the [passThrough,waitFor][0]; code blocks (I guess that is DesignScript?) there to keep the operations all executing in the correct sequence?


And yep again!


This is a great code to parse through.
For the Python portion (creating the corridor surface), I see you use Links to create the surface. I would like to make the surfaces using feature lines instead.

In your code, is “links” just the name for a list of string inputs which are the code for the Top Links? (In this case, just “Top”.) If so, then I should be able to swap in its place a list of codes for multiple feature lines instead…?

Of course I’ll have to switch “surf.AddLinkCode(link, True)” with “surf.AddFeatureLineCode(featureLineName)”
Then, can I presume that “featureLineName” would be referring to the 3rd user input, in this case a set of strings, something like [“Top_curb”,“Back_curb”,“Crown”]?