Context Object Parameters
Table 1. Business Object Standard Parameters
| Parameter Name |
Type |
Read or Write |
Comments |
EVENT |
String |
Read |
Any of the supported events. |
NAME |
String |
Read |
Business object name |
ORGANIZATION |
String |
Read |
The organization that owns the business object
|
OWNER |
String |
Read |
The owner of the business object |
PHYSICALID |
String |
Read |
The physical ID for the business object |
POLICY |
String |
Read |
The business object policy |
PROJECT |
String |
Read |
The project (collaborative space) that owns the
business object |
REVISION |
String |
Read |
Business object revision |
TYPE |
String |
Read |
Business object type |
Table 2. Additional Parameters for copy
| Parameter Name |
Type |
Read or Write |
Comments |
NEWOBJECT |
Object |
Write |
The target object
|
AuditTags |
List |
Read |
Logging event of the transaction. |
Sample
Let listModifiedObjects (List)
Let TargetObject (VPMReference)
Trace(1, "Execution copy_script on ", ThisObject.PLM_ExternalID )
Validation = true
Set TargetObject = Parameters.Macros.GetObject("NEWOBJECT")
if (TargetObject <> NULL)
{
Trace(1, "Test TargetObject.name= ", TargetObject.name )
TargetObject.SetAttributeString("PLMEntity.V_description", "attribute modified by copy_script")
TargetObject.SetAttributeString("description", "basic modified by copy_script")
Trace(1, "TargetObject physicalid = ", TargetObject.GetAttributeString("physicalid"))
listModifiedObjects.Append("B" + TargetObject.GetAttributeString("physicalid"))
ReportModifiedObjects(listModifiedObjects)
}
else
{
ReportUXMessage("NEWOBJECT creation went wrong")
Validation = false
}