Renumbering Piles with spline model line

Hello, I recently watched a great tutorial on how to renumber rooms by spline model line in Dynamo, (http://www.case-inc.com/node/497.html). After watching the tutorial i wondered if this could be done with piles, and i found a site that showed me that it could be done (https://knowledge.autodesk.com/support/revit-products/getting-started/caas/screencast/Main/Details/512ad75f-722a-4d78-9e1b-c84ea685c2e3.html) So i tried to make my own script but i am stuck at the end (see Below)

My question is i want to be able to change the piles mark parameter in Revit by passing a spline model line through the pile caps so that it is in logical order but i cannot seem to figure out how to finish off the script. In the Second tutorial it shows some kind of amendment node (see below) which i cannot seem to find.

Can someone help me complete this script as it would save me and my company hours in time renumbering piles. Thank you

The  Amendment to the room Tutorial

Posting a sample Revit file and your script would help others understand your problem better.

Also, your second screen shot isn’t clear.

Piling test

Pile Auto-Number with Spline type 2

Vikram, i am looking to be able to draw a spline model over the pile caps in the order i want and i want it to be able to change the pile mark parameter in Revit

Hope this makes sense, apparently it can be done but im not sure how to amend the nodes

20160422-2

File: Pile-Auto-Number-with-Spline-type-2

I had to do the same thing. I’ve used the excellent Case node for renumbering rooms and changed a couple things to suit my process. I kept most of the nodes in the Case definition as i wasn’t too sure what i could remove so it isnt very tidy :stuck_out_tongue:

here it is: Renumber along Curve

You can either do a full category, or just select the model elements. Also you can change the format the mark comes out as. In this definition, it is adding a Prefix letter, a specific separator and creating a 3digit number. But you can change to suit your needs.

There is most likely a waaaayyy more elegant and shorter definition to do this, but this one does the job and dosent take long to run.

Hope this helps

Thank you for your reply Vikram, when i treid to run the script i got these errors:

Thank you Alisder, i tried running your script and i seem to be getting the same errors as Vikrams script, is there something i am doing wrong ?

Sorry Kieran, should have said what packages the nodes are from.

You will need to install the Rhythm package (thats what the red nodes are saying)

Alternatively, you can remove the 2 “Rhythm.Toggle” nodes, and just lace the “Select Curve” node into “CurveElement.Curve” node and the “Select Model Elements” node into the “Geometry.BoundingBox” node and “List.FilterByBoolMask” node. Although if you do this, you may need to close and reopen the definition to Re run it.

Let me know how you get on

Try altering only the end of your original script according to the screen shot I’ve provided above.

Assuming it didn’t throw up errors earlier, leave the rest of your script alone.

Vikram - I changed my original script as you said and it came up with no errors but it did not change any of my pile marks in Revit. Is there a node i need to add to add the mark value ? We normally add a prefix to the pile mark such as P1, P2, etc.

Alisder - I delete the Rhythm nodes like you said and ran the script but it only change the pilecap family mark, i want to be able to change the piles that are nested within the pilecap family.

I believe they only need a few more scripts and they would be complete

 

Kieran

Just noticed you have put in “P1” in the number to start from field. Dont do this, set it to just a number (or it wont work), the bit in red bottom right is for adding the prefix to the mark

Here are your files - altered

Also added the prefix “P”

Use Dynamo 0.9.2, it should work fine.

Piling-test.rvt

Pile-Auto-Number-with-Spline-type-2.dyn

2 Likes

Try this Renumber along Curve filtered You can type in the Type name of the Pile you want to use and it will filter the selection. Alternatively, you could put in the type name of the cap you want to exclude and change the output to the “Out” node on the FilterByBoolMask node. You’ll need to make sure the path actually intersects the Piles you are renumbering and not just the caps.

 

Id recommend you go with Vikrams solution.

Always a better choice :stuck_out_tongue:

1 Like

Kind of you Alisder.

But there certainly can be multiple good solutions and the altered file I’ve provided above is certainly not optimized.

Vikram apologies, i may have not explained myself correctly, the piles are nested within the pilecap family, please see Revit file and picture below:

nested pile test

Thanks for the advice Alisder haha

nested piles

 

 

 

 

 

There are a few problems in your file as it is…

Firstly, the nested pile family (Pile Square) isn’t listed in the Family Types node dropdown.

To rectify this you will have to open the Revit family file Pile Square, under Create go to Family Category and Parameters and check the box for Shared

Now load this altered family to your pile cap family file (Pile Cap-4 Square pile)

Check Shared in the same place in pile cap family file too. Now load this family into the project file.

For your definition to work as it is you will now need to ensure that your spline passes by each one of your piles.

Ensure that you lower the spline so that it actually intersects each one of the piles.

In the Dynamo definition, in the Family Types node select Pile Square instead of Pile Cap-4 Square pile

You might have to work your way past some errors as I haven’t actually worked on it.

Hope this helps

Thank you for reply Vikram, In the last Amended script you sent me, i could select the correct family type as shown below. By following your instructions and drawing the spline over the piles it changed the element mark. Thank you for this. Is there a way to add a prefix to this mark ?

Adding a prefix…

Thank you vikram for your time. It’s much appreciated, the script works fantastic. Cheers