Optimizing 3D Polyline Geometry Extraction Workflow

Currently, I have a working script to extract the geometry (chainage, easting, northing, elevation string a, elevation string b, height) of two 3D polylines from CAD layers (specifically, wall top and wall bottom) and export the data into an Excel spreadsheet. This process is performed individually for each wall by layer, which is time-consuming and inefficient for multiple walls (refer to SC01 attached).

I’m exploring the possibility of streamlining this workflow. Specifically, I’m interested in whether it’s feasible to use a list from Excel (e.g., RW-01_B, RW-01_T, RW-02_B, RW-02_T) as the input instead of selecting layers manually. Additionally, I would like the output to be organized in Excel such that each wall layer has its dedicated tab (e.g., RW-01, RW-02).

Is there a way to modify my current script or approach to accommodate these changes? Any suggestions or guidance would be greatly appreciated.

Hello!

Unfortunately your graph is not able to be read, please use the following instructions to produce a readable graph so we might help you.

2 Likes

1 Like

Have you tried to filter on layer that contains “RNW-” and then filter on ends with “_B” and “_T”?

Maybe like this?


Then you will have two lists with same index that can be used for top and bottom line for wall

1 Like

Hi Patrick, I think your suggestion will work fine. How about the output end, is it possible then to create a separate tab for each wall in the same excel file? Thanks

1 Like

Amigo @shane.mccarney buenas.
when you feed the node all objects by layer Dynamo gives you the objects already gruped by layer, means that you can apply any other proces and it will apply the criteria also by this grups, i hope this helps you, not sure if this is what you need!!

1 Like

Not at my computer at the moment but if you combine them in in one list and then to List.Transpose I think you can add them to a excel with top and bottom layer in seperate columns.

Hi Patrick, to transpose the list is this done at the start or at the end creating the data for excel? attached is my working script and CAD file. The required outcome will be to create a filtered list in excel by wall type (Column A)

Thanks

Wall Data 02.dyn (88.3 KB)
Walls 2.dwg (1023.0 KB)

1 Like

Hi Shane
I tried your graph with your dwg.
I think you need to check the wiring, the values comes in wrong order. Regarding your question if it’s possible to have a separate tab for each wall I don’t think so.