Is it possible to set group name with Dynamo?

Is it possible to set group name with Dynamo?

duanx
Autodesk Autodesk
1,223 Views
4 Replies
Message 1 of 5

Is it possible to set group name with Dynamo?

duanx
Autodesk
Autodesk

Hi, 

 

I tried to create a geometry with Dynamo for FormIt and send the geometry back to FormIt. 

 

I also want to set layer information and attribute information for the new created geometry inside geometry, the FormItGroupOptions.SetLayer and FormItGroupOptions.SetAsMesh works without any problem. But I could not find the method to set group name, it seems Dynamo always used the Dynamo Graph name as the Group name, FormItGroupOptions.SetAttributes does not work no matter I input Key as "Group of" or "Name". Could you please let me know if it is possible to set Group name and how? Thanks!

SendToFormIt02_2024-03-18_06-13-25.png

duanx_0-1710757075845.png

 



Xinhua Duan

0 Likes
Accepted solutions (1)
1,224 Views
4 Replies
Replies (4)
Message 2 of 5

josh.goldstein
Community Manager
Community Manager
Accepted solution

Hi @duanx,

 

This is awesome. Thanks for sharing your progress!

 

As you noticed, the group name is always the Dynamo graph name, and there's currently no way to override that.

 

However, you might try setting a string attribute on the group with whatever string you'd like. There's a Dynamo node called FormItGroupOptions.SetAttribute which takes a key and value.

 

You can then view the string attributes by installing the Manage Attributes plugin:

joshgoldstein_0-1710780553344.png

... and then editing the group (to view the attributes placed on the group's history):

joshgoldstein_1-1710780659777.png

 

Hope this helps!




Josh Goldstein
Senior Product Manager
Message 3 of 5

duanx
Autodesk
Autodesk

@josh.goldstein 

Thanks! I understand how to use FormItGroupOptions.SetAttribute node now!

 

Hope we can have the capability to set Group name in future, as we automatically create many objects and use multi SendToFormIt nodes to combine sub-groups, it is important to assign each individual sub-group with a specific name. 



Xinhua Duan

0 Likes
Message 4 of 5

duanx
Autodesk
Autodesk

I got it work right now, for each sub-group, group name is inherited from the corresponding SendToFormIt dynamo node name. For the parent group, it got the name from the dynamo file name *.dyn.

For example, at the graph below, I override the SendToFormIt dynamo node name to SendToFormIt.Cuboid 01 and SendToFormIt.Cuboid 02, the sub-group got the name from this new header. 

SendToFormIt_2024-03-19_11-26-44.png

duanx_0-1710818881654.png

 

duanx_1-1710818906167.png

 

 



Xinhua Duan

Message 5 of 5

josh.goldstein
Community Manager
Community Manager

Yes, it's true that the sub-groups created by the SendToFormIt node do inherit the name of the SendToFormIt node.

 

Sorry for not mentioning that - I was thinking you meant the top-level group, which will always be named with the .dyn name. But yes, sub-groups can be named via renaming the SendToFormIt node! It's awesome and quite flexible.

 




Josh Goldstein
Senior Product Manager
0 Likes