CD5EngineV6R2015 (Object)

Represents the ENOVIA V6 Integration Engine, that is to say the entry point to the CATIA/ENOVIA V6 Integration.

It allows end user to realize the various operations like ENOVIA New
Note that all operations performed from this interface are the same as operations available in the ENOVIA V6 menu in CATIA, unless most of them are executed without panel.
Example:
 The following example indicates how to retrieve the ENOVIA V6 Integration Engine.
 
 Dim oCD5Engine As CD5EngineV6R2015
 Set oCD5Engine = CATIA.GetItem("CD5EngineV6R2015")
 

Properties


Property TemplateTypes() As (Read Only)
Returns (gets) the list of all "Template Types".
Example:
 The following example gets the list of Template Types.  
 
 Dim oTemplateTypes As ENOIACD5TemplateTypes
 Set oTemplateTypes = oCD5Engine.TemplateTypes
 

Methods


Func GetIDFromPhysicalID( iPhysicalID) As
Returns CD5ID of the object for the given PhysicalID.
Parameters:
iPhysicalID
Physical ID of the object
Returns:
The created CD5ID of the object
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
Example:
 The following example returns the ENOIACD5ID of the object:
 
  • iPhysicalID : "6EFB8D2E00008A445257E36100000DF7".
 Dim ID As CD5ID
 Set ID = oCD5Engine.GetIDFromPhysicalID("6EFB8D2E00008A445257E36100000DF7")
 
Func GetIDsFromPhysicalIDs( iPhysicalIDs) As
Returns CD5IDs of the objects for the given PhysicalIDs.
Parameters:
iPhysicalIDs
Physical IDs of the objects
Returns:
The created CD5ID array of the objects
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
Example:
 The following example returns the ENOIACD5IDs of the object:
 
  • iPhysicalIDs : "6EFB8D2E00008A445257E36100000DF7,6EFB8D2E00008A445257E3610000090".
 Dim IDs As CD5IDs
 Set IDs = oCD5Engine.GetIDsFromPhysicalIDs(iPhysicalIDs)
 
Func GetProperties( iENOIACD5ID) As
Returns a collection of all the ENOVIA V6 properties for a given Object defined by Type, Name, Revision & Version.
Parameters:
iENOIACD5ID
The ENOIACD5ID object id representing ENOVIA V6 Object which is to be explored.
Returns:
The collection of properties of the ENOVIA object passes as iENOIACD5ID
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
-1691273589 : Invalid object type
-1857112104 : Name or Type Empty
Example:
 The following example retrieves all the ENOVIA V6 properties from a given ENOIACD5ID.
 
 Dim ObjID As CD5ID
 Set ObjID = oCD5Engine.GetIDFromTNRV("Versioned CATPart", "Part_Name", "A", "0")
 Dim oCD5Properties As CD5Properties
 Set oCD5Properties = oCD5Engine.GetProperties(ObjID)
 
Func GetPropertiesOfDocument( iCATIADocument) As
Returns a collection of all the ENOVIA V6 properties for a given ENOVIA object.
Parameters:
iCATIADocument
The document representing ENOVIA V6 Object which is to be explored.
Returns:
The collection of properties of the ENOVIA object passes as iCATIADocument
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
Example:
 The following example retrieves all the ENOVIA V6 properties for a given ENOVIA object.
 
 Dim docCD5ID As CD5ID
 Set docCD5ID = oCD5Engine.GetIDFromTNR("CATProduct For Team", "MyProduct", "---")
 Dim objDocument As Document
 Set objDocument = oCD5Engine.Open(docCD5ID)
 Dim oCD5Properties As CD5Properties
 Set oCD5Properties = oCD5Engine.GetPropertiesOfDocument(objDocument)
 
Func GetPropertiesOfEmbeddedComponent( iCATIADocument, iEmbeddedComponentName) As
Returns a collection of all the ENOVIA V6 properties for a given Embedded Component.
Parameters:
iCATIADocument
The document representing ENOVIA V6 Object in which the target embedded component resides.
iEmbeddedComponentName
Name of the embedded component to be explored.
Returns:
The collection of properties of the embedded component passed as input
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
Example:
 The following example retrieves all the ENOVIA V6 properties for a given Embedded Component.
 
 Dim docCD5ID As CD5ID
 Set docCD5ID = oCD5Engine.GetIDFromTNR("CATProduct For Team", "MyProduct", "---")
 Dim objDocument As Document
 Set objDocument = oCD5Engine.Open(docCD5ID)
 Dim oCD5Properties As CD5Properties
 Set oCD5Properties = oCD5Engine.GetPropertiesOfEmbeddedComponent(objDocument, "Embedded_Component_Name")
 
Func NewFrom( iCD5Template, iName, iType) As
Creates a new object from given template.
Parameters:
iCD5Template
The Template object from which we want to create a new object.
iName
The name for the new object.
iType
The ENOVIA type for the new object.
Returns:
The created Document.
Throws:
-1697450280 : CATIA is not connected to ENOVIA V6.
-1782306828 : Template object is assigned more than one file.
-1774688310 : Template object is not assigned any file.
-1866082326 : File of same name as that of file attached to Template object is present on checkout directory.
-1739257732 : The name for the new object contains unsupported characters.
-1706631745 : An object with the same name as that of new object is already present in ENOVIA.
-1844336441 : File of same name as that of new object is already present on checkout directory.
Example:
 The following example creates a new object to be loaded in the CATIA session:
 
  • iCD5Template : template.
  • iName : "NewPart".
 Dim types As Array
 types = oTemplateType.PossibleTypes
 Dim document As CATIADocument
 Set document = oCD5Engine.NewFrom(template, "NewPart", types(0))