autodesk-forgeautodesk-viewerautodesk-navisworks

persistence of externalId Navisworks files


I've been using the externalId to uniquely refer to objects in the forge viewer and connect them with outside data about these objects. This has worked well for revit files, which have a kind of GUID 86715290-fa28-4ff5-aef9-8c75d7c81e77-0012917b. Now I'm working with a Navisworks file, and their externalId use looks very different with values like a, 0 or 0/0/0/. How persistent are these, I can imagine not globally unique, but do changes/removals/additions keep them unique within the file? What is the suggested strategy to globally refer to solids in Navisworks files?


Solution

  • The external id of the path through the model selection tree to that element started from 0, see the snapshot below: enter image description here

    As I know:

    In Revit case, it uses a unique id of the element (saying Element.UniqueId of the Revit API) as the externalId. However, the Navisworks doesn't have a concept unique id since it will have to handle different formats and some source models don't have unique id either. Therefore, it uses the selection tree path as the externalId instead.

    Thus,

    To preserve the identity information of the Revit elements, I would like to advise you to add a Revit shared parameter to store the value of the Element.UniqueId, and identify the element by this parameter.