Validate Main View Creation (RFLP_ValidateCreateMainView)

An opening ID is an entry point used to customize business logic. The RFLP_ValidateCreateMainView business logic enables you to validate the creation of a main view under a logical or functional reference.

To validate the creation of a main view, you must declare the file containing the script to be executed in PLMBusinessLogicFLEditor.CATRuleExit:

<Script OpeningID="RFLP_2DMainViewCreation" Type="RFLPLMFunctionalReference" ScriptName="RFLP_ValidateCreate2DMainView"/>
<Script OpeningID="RFLP_2DMainViewCreation" Type="RFLVPMLogicalReference" ScriptName="RFLP_ValidateCreate2DMainView"/>
Note: For more information about customization by business rules, see Customization by Business Rules.

This page discusses:

General Information

This opening ID is invoked when creating a main view using the Insert 2D Main View Representation command.

Definition Description
PLM Opening ID RFLP_ValidateCreateMainView
Customization intent Validation
Execution context Client

Input Objects

Input objects must be of the following types:

  • ThisObject: PrimaryType
  • Parameters corresponds to the context object.
  • Validation
    • If it returns false, the main view is not created and the mask that identifies the missing main view representation is not displayed.
    • If it returns true, the creation of the main view is validated.

Context Object Parameters

Parameter Name Type Read or Write Comments
TName
RFLPLMFunctionalReference RFLVPMLogicalReference or any derived type
Read Types of components under which you want to create a main view.

Sample

The following sample validates the creation of a main view under a logical or functional reference.

Let TName=""
Let PrimaryType(Type)

set PrimaryType = ThisObject.PrimaryType
TName = PrimaryType.Name


if (TName == "RFLPLMFunctionalReference")
               Validation = true
else if (TName == "RFLVPMLogicalReference")
               Validation = true
// Invalidate creation of main view for MyCustomizedTypeName: TName contains MyCustomizedTypeName
else if (TName <> (TName - "MyCustomizedTypeName"))
               Validation = false
else
               Validation = true