Reporting a length of a an adaptive curve / spline using dynamo

Hi,

I came across a Revit question on the autodesk froum where i am experiencing the exact same problem as the previous user:

https://forums.autodesk.com/t5/revit-architecture-forum/reporting-length-of-a-spline/td-p/6675780

In it there is mention of using Dyanmo to determine the length which i am also unfamiliar with but want to use it to find a solution. When i create the script shown by @Alfredo Medina I am getting a blank document at the other end and something is wrong. Could someone go into a little more detail please of the steps required and explain where I may be going wrong. I would like it to output the information as a schedule for all of the different sizes.

I have also put this question on the revit forum with files attached if you wiah to download them as i cannot do it here:

https://forums.autodesk.com/t5/revit-architecture-forum/reporting-a-length-of-a-an-adaptive-curve-spline-using-dynamo/td-p/8134624

Many thanks

Liam

Hi @infoZ9HS2,

You need to deconstruct the family to get the edge curves.

Alfredo Medina’s graph works with a spline not with a family.

Thanks Alban,

I have written the script but am getting 2 errors saying:

Code Block: Warning: The index is outside the given range.

CSV.WriteToFile: Warning: CSV.WriteToFile operation failed.

I think i understand all of the nodes apart from List Sort, Code Block & Watch could you explain these a little please and also what i need to do to make the script work?

Also what type of file must the output file be or is this automatically generated (no file selected) if one is not selected?

Thanks

Liam

@infoZ9HS2 See if this helps…


curveLength.dyn (11.1 KB)

You’ll need to create a blank .csv file and specify the path.

I think i understand all of the nodes apart from List Sort, Code Block & Watch could you explain these a little please and also what i need to do to make the script work?

To explain the logic :
List.sort was to get an order from the list of edges and find the next to last highest value.
The code block is simply a GetItemAtIndex in DesignScript language.

In any case, Vikram Subbaiah’s graph is better because it finds the length of the “axis” of the family and not that of an edge.
So please marks his post as solution to facilitate similar researchs in the future.

1 Like

Finally gotten arond to testing this and it works great. Thanks so much Vikram. Thge only issue is last node: Data.ExportCSV is not in the library? Any ideas where it may be? Or an alternative?

Thanks

Liam

1 Like

Apparently you are using an old version. This is available in ver 2

In 1.3, the equivalent node is …
csv1

OK so i have downloaded the latest veriosn and it works great. The only other element i would like to introduce is to give each sheet a mark. How do I make dynamo report on this? Thanks!