Lifecycle Applications

Engineering Change Management

The Change Management Interfaces

Typical Uses of Change Management Interfaces
Technical Article

Abstract

This technical article shows how to use interfaces of the ENOVInterfaces framework to perform a typical Change Management operation. In this case, we create an Engineering Change Order and a design Action, add an Affected Object, link the Action and add an Effectivity to the ECO.


A Typical Change Management Scenario

This technical article is intended to show you how to use available interfaces in ENOVInterfaces in a typical Change Management scenario. It will demonstrate how to: create an ECO; create a design Action; add an existing object, in this case a part version, as an Affected Object; link the Action to the ECO; and finally add an Effectivity. You would use this operation if for example you would like to direct the modification of a certain part version, for instance, a structural clip. You would like to change the type of fasteners in this clip for future production to a different type. The part version is added to the ECO as an Affected Object and the ECO controls the modification of the part. You would also link a design Action to change the design drawings and other documents to reflect the different fasteners. And you would need to add an Effectivity to the ECO to ensure that all clips produced within a time range will have the different fasteners. The ENOVInterfaces framework contains the interfaces which allow you to perform these typical operations. Those operations including code samples are shown below. To perform these operations, however, some prior work is required which is beyond the scope of this article. For the creation of the part version, the Configured View and the Effectivity, refer to the appropriate documentation.

[Top]

Creating an ECO

The first step is to create an ECO which will control the modification. Refer to use case CAAEviEcoManager for more details on working with ECOs. [1]
    #include "ENOVIBOEcoManager.h"
    #include "CATIEnovCMEco.h"
    #include "CATUnicodeString.h"
	 

These include statements are required for the following operations.

    //--- Create an Engineering Change Order 
    
    CATIEnovCMEco_var Eco = NULL_var;
    CATUnicodeString EcoType("ECO");
    CATUnicodeString EcoVersion("1");
    CATUnicodeString EcoName("ECO123");
    CATUnicodeString EcoPriority("Routine");
    CATUnicodeString EcoTypeCode("Release");
    CATUnicodeString EcoInitialAbstract("Change fasteners in clip p/n 1111 to #6 HI-LOKs.");
 
    rc = spEcoMgr->CreateNewEco( EcoType, 
                                 EcoVersion,
                                 Eco,
                                 EcoName,
                                 EcoPriority,
                                 EcoTypeCode,
                                 EcoInitialAbstract );
                                  
    if ( !SUCCEEDED(rc) || Eco==NULL_var )
    {  
    	cout << "ERROR in creating ECO." << endl << flush;
    	VPMSession::CloseSession();
       	return 3;
    } 
       
    cout << "Created new Engineering Change Order successfully." << endl << flush;
  1. With the ECO manager spEcoMgr a call to member method CreateNewEco is made. The arguments passed are EcoType ("ECO"), EcoVersion ("1"), EcoName ("ECO123"), EcoPriority ("Routine"), EcrTypeCode ("Release"), and EcoInitialAbstract ("Change fasteners in clip p/n 1111 to #6 HI-LOKs").
  2. The method creates a CATIEnovCMEco object (Eco) and returns S_OK when successfully completed. E_FAIL is returned if the create is not successful.

[Top]

Creating an Action

An Action will be required to accomplish the necessary work, that is, change the drawing. The code below shows how to create an Action. The Action will then be linked to the ECO. Refer to use case CAAEviActionManager for more details on working with Actions. [2]
    #include "CATIAFLAction.h"
    #include "CATUnicodeString.h"
    #include "ENOVIBOActionManager.h"
       

These include statements are required for the following operations.

//--- Create a new Action 

    CATIVpmAFLAction_var Action = NULL_var;
    CATUnicodeString ActType("Action_Design");
    CATUnicodeString ActName(DSG123");
    CATUnicodeString ActPriority("Routine");
    CATUnicodeString ActInitialAbstract("Change DWG1111 to reflect #6 Hi-Loks in p/n 1111 clip.");
    
    rc = spActMgr->CreateNewAction( ActType, 
                                  DsgAct,
                                  ActName,
                                  ActPriority,
                                  ActInitialAbstract );
                                  
    if ( !SUCCEEDED(rc) || DsgAct==NULL_var )
    {   
    	cout << "ERROR in creating Action." << endl << flush;
    	VPMSession::CloseSession();
       	return 3;
    }    
    cout << "Created new Action successfully." << endl << flush;
  1. With the Action manager spActMgr, a call to member method CreateNewAction is made. The arguments passed are ActType ("Action_Design"), ActName ("DSG123"), ActPriority ("Routine"), and ActInitialAbstract ("Change DWG1111 to reflect #6 Hi-Loks in p/n 1111 clip").
  2. The method creates a CATIVpmAFLAction object (DsgAction) and returns S_OK when successfully completed. E_FAIL is returned if the create is not successful. 

[Top]

Adding an Affected Object to an ECO

Now add an Affected Object to the ECO. Note that the part version type object has been previously created, and in this case would refer to the p/n 1111 clip. Refer to use case CAAEviAffectedObjects for a more details on working with Affected Objects. [3]
    #include "ENOVICWAffectedObjects.h"
    #include "CATIVpmAFLAffectedObject.h"
    #include "CATUnicodeString.h"
    

These include statements are required for the following operations.

//--- Add Clip Part Version as an Affected Object to ECO
  
    CATUnicodeString AOType("ENOVIA_CMAFFECTED_OBJECT");
    CATIVpmAFLAffectedObject_var AffObj = NULL_var;
    ENOVICWAffectedObjects_var spAffObj(Eco);
        
    rc = spAffObj->AddAffectedObject(ClipPartVersion, 
    				    AOType,
    				    AffObj);
    
    if (AffObj==NULL_var||rc!=S_OK)
    {
    	cout << "Failed to Add Affected Object." << endl;    
    	VPMSession::CloseSession();
    	return 7;
    }

    cout << "Added Affected Object succesfully." << endl;    
      
  1. You can use the ENOVICWAffectedObjects interface to add the Affected Object to the ECO.
  2. First, the ECO object, Eco, is cast as a ENOVICWAffectedObject type - spAffObj.
  3. With the type AOType set as "ENOVIA_CMAFFECTED_OBJECT", spAffObj calls method AddAffectedObject.
  4. The method returns S_OK if successful and the affected object AffObj is created.

[Top]

Adding an Action to an ECO

The next step is to link the Design Action to the ECO as a deliverable. Refer to use case CAAEviLinks for a more details on creating different types of links. [4]
    #include "ENOVICWLinks.h"
    #include "CATIVpmAFLLink.h"
    #include "CATUnicodeString.h"
     

These include statements are required for the following operations.

//--- Create a Deliverable Link from ECO123 to the Design Action

    CATIVpmAFLLink_var LinkObj = NULL_var;
    boolean IsPaste = FALSE;
            
    rc = spLink->CreateDeliverableLink(DsgAct, LinkObj, IsPaste);
   
    if (LinkObj==NULL_var||!SUCCEEDED(rc))
    {
    	cout << "ERROR to Add Deliverable Link." << endl << flush;    
    	VPMSession::CloseSession();
    	return 8;
    }
    cout << "Created Deliverable Link successfully." << endl << flush;
      
  1. First, the link-to action is the Design Action, DsgAct.
  2. The ECO object, Eco, is cast as a ENOVICWLinks type - spLink. The boolean IsPaste indicates if the link is being made as a result of a cut and paste.
  3. Then, spLink calls method CreateDeliverableLink.
  4. The method returns S_OK if successful and the link object LinkObj is created.

[Top]

Adding an Effectivity to an ECO

The next step is to link the Effectivity to the ECO. Note that this Effectivity and the Configured View have been previously created and that this operation simply adds the Effectivity to the ECO. Refer to documentation for Product Editor for information on creating a Configured View and an Effectivity. Refer to use case CAAEviConfiguredViews for a more details on adding and removing Effectivities and Product Views to Change Management objects. [5]

    #include "ENOVICWConfiguredViews.h"
    #include "CATIEnovCMEffectivity.h"
    #include "CATUnicodeString.h"
    

These include statements are required for the following operations.

//---Add Effectivity for the clip to the ECO
 
    CATUnicodeString prodName("Clip");
    CATUnicodeString EffId("Mod1");
    CATIEnovCMEffectivity_var ecoEff = NULL_var;
    ENOVICWConfiguredViews_var spCfgView(Eco);
       
    rc = spCfgView->AddNewEcoEffectivity(CV1, 
    					 prodName,
    					 EffId,
    					 ecoEff);
    
    if (ecoEff==NULL_var||!SUCCEEDED(rc))
    {
    	cout << "ERROR in adding Effectivity to ECO." << endl << flush;    
    	VPMSession::CloseSession();
    	return 12;
    }
    cout << "Added Effectivity to ECO successfully." << endl << flush;   
      

 

  1. You can use the ENOVICWConfiguredViews interface to add the configured view to the ECO.
  2. The existing Configured View with its Effectivity is the CV1 variable. The ECO object, Eco, is cast as a ENOVICWConfiguredViews type - spCfgView.
  3. With the prodName set as "Clip" , the EffId set as "Mod1", spCfgView calls method AddNewEcoEffectivity.
  4. The method returns S_OK if successful, the Effecitivity is added to the ECO and the Effectivity object ecoEff is created.

[Top]


In Short

The basic operations in the Change Management domain can be accomplished using interfaces available in the ENOVInterfaces framework. Refer the use cases listed in References below for the different interfaces for examples of how to apply the methods available.

[Top]


References

[1] The ECO Manager Interface
[2] The Action Manager Interface
[3] The Affected Objects Interface
[4] The Links Interface
[5] The Configured Views Interface
[Top]

History

Version: 1 [Feb 2002] Document created
[Top]

Copyright © 2002, Dassault Systèmes. All rights reserved.