DATAKIT API  V2025.4
How to handle NX ReferenceSet

Reference Sets are used to control the visibility and content of parts and assemblies.

Reference Sets define which geometry, bodies, or features of a part are visible when the part is added to an assembly.

The Blanked status in datakit classes is already managed, they give you the final status.

If you want to manage Reference Sets like in NX software, you need to:

Retrieve the ReferenceSet used in a part.

To get the name of the reference set In the Dtk_Info of the Dtk_Component use the method:

Dtk_Info::GetConfigurationName();

Retrieve the list of ReferenceSets to which each entity belongs.

In the Dtk_Info of the Dtk_Node use the method :

Dtk_tab<Dtk_string> Array;
Dtk_Info::GetReferenceSet( Array, DTK_TRUE );

Detailled Sample

In Nx :

  • 'configuration_assm.prt' is an assembly containing one Arrangement (Arrangement1) containing 2 instances of same part ('reference_set.prt') but activationg different reference_set (CYLINDRE , BLOCK)
  • 'reference_set.prt' is a part with several solid belonging to reference_set

In Datakit classes you get :

  • Dtk_Component with type CatalogComponentType containing the list of arrangement - only one in this case. It contains :
    • Dtk_Component with type VirtualComponentType : Arrangement 1. In the Dtk_info of this component you have field Dtk_Arrangement set to TRUE. It contains :
      • Dtk_Component with type InstanceComponentType CYLINDRE that instance reference_set.prt using reference set CYLINDRE
        • It contains a Dtk_Component with PrototypeComponentType representing the part reference_set.prt with the visibility status on each Dtk_Node that correspond to the reference_set activated
        • To Retrieve the ReferenceSet used in a part use the method: Dtk_Info::GetConfigurationName();
        • On each Dtk_Node you can have the list of reference_set he belongs to
      • Dtk_Component with type InstanceComponentType BLOCK that instance reference_set.prt using reference set BLOCK
        • It contains a Dtk_Component with PrototypeComponentType representing the part reference_set.prt with the visibility status on each Dtk_Node that correspond to the reference_set activated
        • To Retrieve the ReferenceSet used in a part use the method: Dtk_Info::GetConfigurationName();
        • On each Dtk_Node you can have the list of reference_set he belongs to

Virtual Component Arrangement 1

Instance CYLINDRE Uses reference_set CYLINDRE

The Dtk_Node type Body with ID 3 belongs to references set : MODEL, CYLINDRE, ALL

His blanked status is set to 1 when he comes from instance BLOCK but not from the instance CYLINDRE because it belongs to the activated reference_set of these instance.

Blanked in prototype loaded by "BLOCK" instance

Visible in prototype loaded by "CYLINDRE" instance

No attribute Dtk_BlankedSatus