Get user text Attributes of Rhino object in order


Iam baking geometries using Elefront where it sets to each object own tree path and branch id as user text attributes.

how to get in C# the guid of the geometries also in the same order by iteration user text attributes?
0-BM_III.3dm (2.1 MB) (6.2 KB)

Hi @MomoJawad,

I am not exactly sure what you are trying to do. EleFront should be able to hand all user text sorting, filtering, etc. I opened the .3dm file you provided and I don’t see any user text on the geometry. Perhaps you can explain a bit more what you are trying to do.



Iam Baking geometries with certrain datatree structure:

Then in another Grasshopper file iam refering to these geometries:

So i need to get Guid of each object inside “Elefront::kansi” layer in the same order inside C# component
I know i can just input Guid component and get them in order. Like this:

But i need to make it inside C# component

So, inside C# iam searching for object that has name “Elefront::kansi” and then fetching their Guid values, but the order is not same. As far as i understood, Elefront gives order number of each geometry and saves it to usertext attribute when baked. and then we refering in other grasshopper, it sorts the geometries and creates Datatree according to the user attributes:

So in C# after searching for each object that has name “Elefront::kansi”. I want to access it is user attributes to fetching the values that in which path and branch number the geometry exits and then i want to create same datatree of their Guid.

Hopefully i explained the situation clearly.

I am not sure why you need to use a custom C# component to access the user text, eleFront should do that. However, why don’t you just feed the the GUIDs to C# as sorted by eleFront so that you are ensured that the data trees are synced up.

I see that you are using Rhino 7 from you screenshots. I would recommend using the latest eleFront 5.0.5 for Rhino 7. For example, we have removed the “maintain tree structure” in the R7 release as any sorting or filter can easily and should be done using key-value pairs.

In the image below the R7 version of eleFront is running along with the R6 version of eleFront. You can see in 1) that the GUID is passed through the C# component and the tree maintained when “item access” is enabled and 2) the user text is available through the attributes stored on the geometry, in this case you are seeing the attribute container since no actual user text is stored on the geometry in your example.