Hi everyone,
I’m trying to create the automatic cable trays/Conduit based on two Different Cooridnate value with Dynamo.
I have two coordinates (XYZ value) points A & B and Tray details like Type, Width, Height at XL format.
So, my point is based on data available in excel sheet, automatically create the cable trays/Conduit in Model.
I know its crazy idea!!!
Any suggestions?
Revit XY.xlsx (9.5 KB)
Thanks
Hi,
you can use CableTray.ByLines from MEPover package.
You need to create points from your excel coordinates, then Line.ByStartEndPoint and then CableTray.ByLines.
Give a try and post your graph
1 Like
Hi Lucamanzoni,
I tried created Line by using From and To points by XL input. Point A to B.
I think something missing in my graph.
Pls suggest to create multi line by using below different Points.
For Example:
Point-A |
Point-B |
A-0001 |
A-0002 |
A-0003 |
A-0004 |
A-0005 |
A-0004 |
A-0001 |
A-0006 |
A-0006 |
A-0007 |
A-0007 |
A-0008 |
A-0008 |
A-0009 |
A-0009 |
A-0010 |
A-0015 |
A-0016 |
A-0013 |
A-0012 |
A-0013 |
A-0014 |
A-0014 |
A-0015 |
I tried with your files, you need to use Clean after reading the data, because for some reason there were some Null rows.
After that, just Transpose and get the separate columns with GetItemAtIndex (or CodeBlock)
You need a bit of filtering to get the TrayTypes, but the rest is quite fast and easy
1 Like
Hi Lucamanzoni,
Thanks for your input, its working fine.
I have issue with creating tray in model
Anything i need to change in XL sheet Like Tray Type or Size.
Could you please help me out.
Type |
Tray Width |
Tray Height |
Point Number-A |
Point Number-B |
Channel Cable Tray |
600 |
100 |
A-0001 |
A-0002 |
Ladder Cable Tray |
300 |
50 |
A-0003 |
A-0004 |
Channel Cable Tray |
600 |
100 |
A-0005 |
A-0004 |
Ladder Cable Tray |
300 |
50 |
A-0001 |
A-0006 |
Channel Cable Tray |
600 |
100 |
A-0006 |
A-0007 |
Ladder Cable Tray |
300 |
50 |
A-0007 |
A-0008 |
Channel Cable Tray |
600 |
100 |
A-0008 |
A-0009 |
Ladder Cable Tray |
300 |
50 |
A-0009 |
A-0010 |
Channel Cable Tray |
600 |
100 |
A-0018 |
A-0019 |
Ladder Cable Tray |
300 |
50 |
A-0013 |
A-0012 |
Channel Cable Tray |
600 |
100 |
A-0013 |
A-0014 |
Ladder Cable Tray |
300 |
50 |
A-0014 |
A-0015 |
Thanks
The problem is in the upper part, you have elements with the same name and that results in a double counting (24 instead of 12). You need to have 12 types, 12 lines, 12 thickness etc…
Try with a List.Unique node after Element.Name or with a List.FirstItem after List.AllIndicesOf.