UniqueID missmatch between a link element and element inside the link

Hi guys,
I am trying to match elements from a Revit model (using the uniqueID) in Dynamo, but I have noticed that the ID’s are different for the link instance element and the element Unique ID if I open the link type.

My idea is that possibly the link instance instantiates a new object and gives it a new UniqueID, when it is hosted inside a site model (link host). I can’t seem to find a way to access the link type elements from the site model to validate my hypothesis. Has anyone experienced anything similar?


Are you getting the GUID from the link instance in the active project, or the instance in the backgroun opened copy of the linked document?

Hi Jacob,
It’s a link instance in the active project. I have 30 or so link types loaded, and they have multiple instances of the link positioned. Then I’m using Bimorph nodes to query the link elements. But that let’s me only query the link instances, and not the types, or I don’t know how to access the types.

So the hypothesis seems correct from the standpoint of current data you are getting and a logical standpoint as all GUIDS should be unique.

That said, we haven’t seen how you are accessing it, nor have you provided a data set so we can’t confirm.

Rather than chasing this down, perhaps it is easier to review the end goal. What is it you were going to use the GUID for?

I have a work-around in place, which is getting the UniqueID and setting it in a custom shared parameter, which does not vary per group. Then I am retrieving this parameter from the link instances. Though it would be much easier to access the link type and just retrieve the type UniqueID, which should then match. But how to access the link type in Dynamo? Bimorph lets me access only link instances. And yes, I can access element types of a link instance, but that doesn’t cut it.

My use case is that I am matching the elements in a cloud database and one of plugins that export the 3D mesh uses the unique ID as row ID. I would appreciate simplyfing the process by not having to populate each link (And all elements of categories it contains) with a shared parameter and reporting the ID’s, and instead, figure a way to read the UniqueIds directly from link type element instances. Can this be done? :slight_smile:

Why not?

From each link instance, get the type, get the associated element out of the type, then do what you want with that data. My guess is that the only possible issue would be using the link type is going to create a duplicate value, but with what you are sharing I can’t tell. If that is the case then you’d need to use the GUID from the instance to store the data, but read the data from the related element in the link type. My guess is this is what you’re doing now via the intermediate parameter.