Creating groups in civil 3D

Trying to create one group of the elements in the green circle with the help of Dynamo because there are 500 elements, so I just want to automate it.

Hi and Welcome.
How do you want to group them? Based on layer, some values in a property set?

Thanks for your comment patrick,

based on their names. So just these two elements should be in one group. I hope I’m explaining it correctly

Question… the element, are they some kind of blocks that holds name or what are they?

They’re basically railway line components and yes they hold separate names and are blocks.

Can we connect on email or anywhere for faster communication?

Please stick to the open forum, this way the larger community can benefit rather than just your project.

Make sure your forum account is set up right and you should get notifications in your email (and you can actually reply from there as well).

3 Likes

Yes, as @jacob.small say, please stick to the forum. I will not use email because it will be hard to follow up and help other users.

Well, it’s still sunday in my part of the world and I where at the gym so that was the reason I didn’t answer right away.

There seems not to be a perfect solution and function in Dynamo to retrieve all objects and group them.
Depending on how you would like to group them you can send command to command line using my uploaded example but as I did with Block references and filter on their block names. In the best world I would like to be able to help you to cycle through all objects and sort them based on their names but I don’t know how for the moment. Can you send a dwg file with just a few different object, then it will be easier to test.

2 Likes

You’re right Jacob. I’ll stick to this forum

No problem Patrick and yes guys are right, I’ll stick to this forum.

Thanks for sharing the script, I’ll try it and will send the Civil 3D Dwg file in couple of hours.

Hello Patrick,

It’s not allowing me to attach dwg file here, it says “New users can’t upload files”
So I’m sharing it through we-transfer link- I hope it’s okay

Thanks a lot for your help.

1 Like


Do I have to put the block names here?

Hi
Maybe it was a bad example.
I had a lot of blocks that started with a prefix with a length of 4 letters so I used that node to filter them out.
I will investigate your file and try to give you a better solution.

1 Like

Thank you. Looking forward to it

I’m not sure how to fix this, I tried to find any similarities between the object that you wanted to group but I can’t find any.
What have you tried so far? Any script that you can share, or have you find any similarities such as layers, or naming that you can point out

1 Like

I’m still trying. I tried skipping the grouping part and started placing them on their place.

We can point out the elements by their “Object type”. Following are the object types

  1. ALS_SIG_Hellfire Machine:900
  2. ALS_SIG_GM4000A Switch Machine:Support Switch Machine
1 Like