Rotate specific columns around independent Z axis

I have seen many Dynamo scripts use the FamilyInstance.SetRotation node, which would work wonderfully if it didn’t rotate every single column in the project. Is there a workaround or another way to make it so only my selected columns rotate.

E.g. I only have two structural columns selected but it rotates all columns in my project

You could rotate the elements rather than the families (as the families represent all instances of your elements).

Hi @B3nj117,

You can use the Id to filter the selected columns.

The selected elements are already family instances. There’s no need for any other nodes, just input them directly into SetRotation.

I tested with dynamo 1.3 and 2.1 and I’ve this error.

Error

There is a difference between these elements :

I basically copied the format you have here, but the columns do not rotate. No errors though.

It’s odd.
Can you show your graph with the previews under nodes unpinned ?

List.Contains need to be set on longest lacing.
Lacing

FamilyInstance.SetRotation needs to be set on level 1.
level

Can you mark the post as solved if it works ?
Solved

Here it is the graph for dynamo 2.0

Rotate specific columns V2.0.dyn (23.2 KB)

EDIT : First graph with proper lacing

I have an issue with the Elements.Type node. My Dynamo Revit version is 2.0.1.5065
image

You can probably use Element.ElementType node instead.

It rotated one of two columns I selected, then didn’t work on any others

This worked, sort of. I selected one column and three of them moved. Not sure how

It works well for me.

Rotate specific columns V2.0.dyn (17.8 KB)

I don’t know what I did differently, but your dyn file worked. Thank you!!!

It’s all about what you select to rotate, some colums or all of them.
See the green indicators (Id’s) ?
That gives you the instances (individual columns)
If you select the family, you get all of those family (lots of Id’s)