Example script, crossing of 3D polylines with an alignment and save the layer and stationing to an excel file

I needed a list of every cable / duct / pipe, represented as 3D polylines, that crosses the Alignment for a pipeline project.

This is the script I created. Sharing is caring.
First part is a check to see what crosses, any 3D polyline that doesn’t cross the Alignment gets set at a different layer.
Second step is getting station number and layer of the 3D polyline that crosses and saves it to an excel file. Any errors are being set at a different layer.


Kruising LER met Alignment.dyn (137.0 KB)

Tips, tricks or comments are welcome.

Good job. For feedback, main thing I think is you can shift away with having to break everything down to points then redrawing in Dynamo, instead to use the direct geometry and intersect. I like to place circles in model space to see where there is a clash. In the excel output you can add headers by using additemtofront of the list. Attached is my rendition. Polylines intersect with Alignment v2.dyn (100.6 KB)

Thank you Kirk for your reply. Lots to make use of and will change my script a little.

I get the circles, was looking for something like that, but the alignment is 73km long, with over 400 cables / ducts / pipes crossing it, which gave me a little too much objects to check.

Thank you again!