Anormal modification of Element.UniqueId
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
We encounter a problem with the management of the GUID collected by the "Element.UniqueId".
- When deleting an element, and then use the Undo function, the element that reappears has still the same ID and the same UniqueId.
- In the other case, if after deleting it, we save the project and then use the Undo function, the element that reappears has still the same Id but the UniqueId changed!
- The same problem also exists with IFC GUID.
This bug causes obviously a very big problem in the management of plugins that manage an external database or other tools using the IFC export.
Revit API’s documentation specifies that you can not directly use the id:
// Résumé :
// A stable unique identifier for an element within the document.
//
// Notes :
// The UniqueId can be used to store an identifier in an external database and to
// retrieve the same element in the future if it still exists. This id can be passed
// to the Document's Element property to retrieve the element. The UniqueId is stable
// across upgrades and workset operations such as Save To Central, while the Autodesk.Revit.DB.ElementId
// property may change.
We encountered this problem with the Revit 2016 Build 16.0.1144.0 and also the previous one.
Is there a feature or trick to skirt it?