PLMEnsRefEquipment.CreateRacewayReplicatePort()
Lets
you replicate Raceway ports.
Raceway_Part.CreateRacewayPort()
Lets you create raceway ports.
Signature
Raceway_Part.CreateRacewayPort(X_OriginPt : Real, Y_OriginPt : Real, Z_OriginPt : Real, X_AlignDir : Real, Y_AlignDir : Real, Z_AlignDir : Real, X_OrientDir : Real, Y_OrientDir : Real, Z_OrientDir : Real, PortType : RacewayPort_Types, PortName : String, X_OffsetPoint : Real [, Y_OffsetPoint : Real, Z_OffsetPoint : Real]) : Raceway_PartPort
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
X_OriginPt |
In |
|
Real |
Defines the center point of the port: X
coordinate |
Y_OriginPt |
In |
|
Real |
Defines the center point of the port: Y
coordinate |
Z_OriginPt |
In |
|
Real |
Defines the center point of the port: Z
coordinate |
X_AlignDir |
In |
|
Real |
Defines the alignment direction: X
coordinate |
Y_AlignDir |
In |
|
Real |
Defines the alignment direction: Y coordinate
|
Z_AlignDir |
In |
|
Real |
Defines the alignment direction: Z coordinate
|
X_OrientDir |
In |
|
Real |
Defines the orientation direction: X
coordinate |
Y_OrientDir |
In |
|
Real |
Defines the orientation direction: Y
coordinate |
Z_OrientDir |
In |
|
Real |
Defines the orientation direction: Z
coordinate |
PortType |
In |
|
RacewayPort_Types |
Defines the type of the port from the
predefined list in RacewayPort_Types |
PortName |
In |
|
String |
Defines the name of the port |
X_OffsetPoint |
In |
No |
Real |
If the port type is two points part or hole
port, you must define the offset from the center of the port
|
Y_OffsetPoint |
In |
No |
Real |
- |
Z_OffsetPoint |
In |
No |
Real |
- |
ReturnType
Raceway_PartPort
Example
/*To create a two point hole port on raceway part*/
prd is Raceway_Part
let X_OPt(Real)
let Y_OPt(Real)
let Z_OPt(Real)
X_OPt=0
Y_OPt=0
Z_OPt=0
let X_alignDir(Real)
let Y_alignDir(Real)
let Z_alignDir(Real)
X_alignDir=0
Y_alignDir=0
Z_alignDir=2
let X_orientDir(Real)
let Y_orientDir(Real)
let Z_orientDir(Real)
X_orientDir=0
Y_orientDir=2
Z_orientDir=0
let X_offsetpt(Real)
let Y_offsetpt(Real)
let Z_offsetpt(Real)
X_offsetpt=2
Y_offsetpt=0
Z_offsetpt=0
let porttype(RacewayPort_Types)
porttype= "CATRcw2HolePort"
let portName(String)
portName = "test1"
let port(Raceway_Port)
Message("CreateRacewayPortCalled")
port = prd. CreateRacewayPort(X_OPt, Y_OPt, Z_OPt, X_alignDir, Y_alignDir, Z_alignDir, X_orientDir, Y_orientDir, Z_orientDir, porttype,
portName, X_offsetpt,Y_offsetpt,Z_offsetpt)
Raceway_Part_Occurrence.GetAttributeOnConnectedPorts()
Method used to read the port attributes (lengths) on the connected
raceway parts.
Signature
Raceway_Part_Occurrence.GetAttributeOnConnectedPorts(Linked Object : Raceway_Part_Occurrence, Attribute : String, This Object Value : String, Linked Object Value : String) : Integer
Arguments
| Name |
Input / Output |
Required? |
Type |
Comment |
Linked Object |
In |
Yes |
Raceway_Part_Occurrence |
|
Attribute |
In |
Yes |
String |
The list of attributes comes from the
Raceway_PartPort object. |
This Object Value |
Out |
Yes |
String |
|
Linked Object Value |
Out |
Yes |
String |
|
Raceway_Part_Occurrence.GetAttributeOnConnectedPorts()
Method used to read the port attributes (lengths) on the connected
raceway parts.
Signature
Raceway_Part_Occurrence.GetAttributeOnConnectedPorts(Linked Object : Raceway_Part_Occurrence, Attribute : String, This Object Value : LENGTH, Linked Object Value : LENGTH) : Integer
Arguments
| Name |
Input / Output |
Required? |
Type |
Comment |
Linked Object |
In |
Yes |
Raceway_Part_Occurrence |
|
Attribute |
In |
Yes |
String |
The list of attributes comes from the
Raceway_PartPort object. |
This Object Value |
Out |
Yes |
LENGTH |
|
Linked Object Value |
Out |
Yes |
LENGTH |
|
ReturnTypeInteger Return code:
- 0: Attribute values successfully read.
- 1: Attribute not found on ThisObject.
- 2: Attribute not found on iOccurrence.
- 3: Invalid attribute.
Raceway_Part_Occurrence.GetRelatedObjects()
Method used to return the connected objects.
Raceway_Part_Occurrence.GetSpoolName()
Method used to return the spool name.
Signature
Raceway_Part_Occurrence.GetSpoolName() : String
Raceway_Part_Occurrence.GetSpoolObject()
Method used to return the spool object.
Signature
Raceway_Part_Occurrence.GetSpoolObject() : Raceway_Spool_Occurrence
ReturnType
Raceway_Spool_Occurrence
Raceway_Port.CheckCompatibility()
Raceway_Port.CheckCompatibility()
Signature
Raceway_Port.CheckCompatibility(Port Owner Occurrence : ProductOccurrence, Second Port : VPMPort, Second Port Owner Occurrence : ProductOccurrence, Use Only Compatibility Rule Table : Boolean, List of Additional Specifications : List, Parameters whose check failed : List) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
Port Owner Occurrence |
In |
|
ProductOccurrence |
- |
Second Port |
In |
|
VPMPort |
- |
Second Port Owner
Occurrence |
In |
|
ProductOccurrence |
- |
Use Only Compatibility Rule
Table |
In |
|
Boolean |
- |
List of Additional
Specifications |
In |
|
List |
- |
Parameters whose check
failed |
Out |
|
List |
- |
Raceway_Port.GetOffsetPort()
This
method allows you to find the publication of an offset port if the port is a
two-point part port or a two-point hole port.
Signature
Raceway_Port.GetOffsetPort(OffsetPort : PLMPort) : Boolean
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
OffsetPort |
Out |
|
PLMPort |
-
|
ReturnType
Boolean
This Boolean can return two values:
- True: the function succeeds.
- False: the function fails.
Example
let PLM_port(PLMPort)
let rcd_port(Raceway_Port)
let list_child_Part(List)
let index(Integer)
let port_types(RacewayPort_Types)
let bStatus(Boolean)
let oPLMPort(PLMPort)
let RacewayPrtOcc(Raceway_Part_Occurrence)
if (RacewayPrtOcc <> NULL)
{
list_child_Part = RacewayPrtOcc.Children
for index=1 while index <= list_child_Part->Size()
{
set PLM_port = list_child_Part[index]
if(PLM_port <> NULL)
{
Trace(1, "Got the PLM Port", "")
set rcd_port = PLM_port
if(rcd_port <> NULL)
{
Trace(1, "Got the Raceway part Port", "")
bStatus = rcd_port->GetPortType(port_types)
if(bStatus == true)
{
Trace(1, "Getting port type successfully", "")
Trace(1, "Type is: ", port_types)
}
bStatus = rcd_port->GetOffsetPort(oPLMPort)
if(oPLMPort <> NULL AND bStatus == true)
{
Trace(1, "PLM Port received from method", "")
}
}
}
}
}
Raceway_Port.GetPortType()
This
function allows you to find the type of the selected port.
ReturnType
Boolean
This Boolean can return two values:
- True: the function succeeds.
- False: the function fails.
Example
let PLM_port(PLMPort)
let rcd_port(Raceway_Port)
let list_child_Part(List)
let index(Integer)
let port_types(RacewayPort_Types)
let bStatus(Boolean)
let oPLMPort(PLMPort)
let RacewayPrtOcc(Raceway_Part_Occurrence)
if (RacewayPrtOcc <> NULL)
{
list_child_Part = RacewayPrtOcc.Children
for index=1 while index <= list_child_Part->Size()
{
set PLM_port = list_child_Part[index]
if(PLM_port <> NULL)
{
Trace(1, "Got the PLM Port", "")
set rcd_port = PLM_port
if(rcd_port <> NULL)
{
Trace(1, "Got the Raceway part Port", "")
bStatus = rcd_port->GetPortType(port_types)
if(bStatus == true)
{
Trace(1, "Getting port type successfully", "")
Trace(1, "Type is: ", port_types)
}
bStatus = rcd_port->GetOffsetPort(oPLMPort)
if(oPLMPort <> NULL AND bStatus == true)
{
Trace(1, "PLM Port received from method", "")
}
}
}
}
}
Raceway_Port.SetPortAttributeReal()
Lets you modify the port attribute when its type is real.
Signature
Raceway_Port.SetPortAttributeReal(AttrName : String, AttrValue : Real)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
AttrName |
In |
|
String |
Name of the attribute you want to modify
|
AttrValue |
In |
|
Real |
New value you want to set on this attribute
|
Raceway_Port.SetPortAttributeString()
Lets you modify the port attribute when its type is string.
Signature
Raceway_Port.SetPortAttributeString(AttrName : String, AttrValue : String)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
AttrName |
In |
|
String |
Name of the attribute you want to modify
|
AttrValue |
In |
|
String |
New value you want to set on this attribute
|
Raceway_Tray.Add3DPoint()
Lets you add a list of points.
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iListPoint |
In |
|
List |
List of the GSM point coordinates |
iIndex |
In |
|
Integer |
Points are adding after this input Index. If
you want to add a point before the first index, the value must
be "0". |
Raceway_Tray.GetColor()
Lets you retrieve the color of the tray from the geometrical
feature.
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
oRed |
Out |
|
Integer |
Value between 0 and 255 |
oGreen |
Out |
|
Integer |
Value between 0 and 255 |
oBlue |
Out |
|
Integer |
Value between 0 and 255 |
Example
let Red(Integer)
let Green(Integer)
let Blue(Integer)
Red = 120
Green =180
Blue = 255
let R(Integer)
let G(Integer)
let B(Integer)
Message("SetColor Called")
prd.SetColor(Red, Green, Blue)
Message("GetColor Called")
prd.GetColor(R, G, B)
if( ( Red == R) and (Green == G) and ( Blue == B) )
{
Message("color set and get are equal ")
Message("color set ", Red ,Green , Blue)
Message("colorGet" ,R ,G , B)
}
else
{
Message("set color is different from get color ")
}
Raceway_Tray.GetDefaultBendRadius()
Raceway_Tray.GetDefaultBendRadius()
Signature
Raceway_Tray.GetDefaultBendRadius(oDefaultBendRadius : LENGTH)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
oDefaultBendRadius |
Out |
|
LENGTH |
Default bend radius value existing on the
current route. |
Raceway_Tray.GetMinimunStraightLength()
Raceway_Tray.GetMinimunStraightLength()
Signature
Raceway_Tray.GetMinimunStraightLength(oMinimumStraightLength : LENGTH)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
oMinimumStraightLength |
Out |
|
LENGTH |
Minimum straight length value on the route.
|
Raceway_Tray.GetNodeBendRadius()
Raceway_Tray.GetNodeBendRadius()
Signature
Raceway_Tray.GetNodeBendRadius(iIndex : Integer, oRadius : LENGTH)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iIndex |
In |
|
Integer |
Node index at which user needs a bend radius.
|
oRadius |
Out |
|
LENGTH |
Node bend radius value at existing node index.
|
Raceway_Tray.GetNodeType()
Raceway_Tray.GetNodeType()
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iIndex |
In |
|
Integer |
- |
oEnumNodeType |
Out |
|
RacewayNodeType |
CATRwyTrayPortPoint,
CATRwyTrayDirectionalPoint, CATRwyTrayComputedPoint,
CATRwyTray3DPoint, CATRwyTrayParallelPoint |
Raceway_Tray.GetOpacity()
Raceway_Tray.GetOpacity()
Signature
Raceway_Tray.GetOpacity(oOpacity : Integer)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
oOpacity |
Out |
|
Integer |
- |
Raceway_Tray.GetSectionOrientation()
Raceway_Tray.GetSectionOrientation()
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
oEnumOrientationType |
Out |
|
RacewayOrientation |
CATRwyTrayVerticalUp, CATRwyTrayVerticalDown,
CATRwyTrayHorizontalLeft, CATRwyTrayHorizontalRight |
Raceway_Tray.RemoveNode()
Lets you remove a list of nodes from the reference route.
Signature
Raceway_Tray.RemoveNode(iListIndex : List) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iListIndex |
In |
|
List |
List of node index positions that need to be
removed from the reference route |
Raceway_Tray.ResetNodeBendRadiustoDefault()
Raceway_Tray.ResetNodeBendRadiustoDefault()
Signature
Raceway_Tray.ResetNodeBendRadiustoDefault(iIndex : Integer)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iIndex |
In |
|
Integer |
Node index at which user resets the bend
radius to default bend radius. |
Raceway_Tray.SetColor()
Lets you set the color of the tray from the geometrical
feature.
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iRed |
In |
|
Integer |
Value between 0 and 255 |
iGreen |
In |
|
Integer |
Value between 0 and 255 |
iBlue |
In |
|
Integer |
Value between 0 and 255 |
Example
let Red(Integer)
let Green(Integer)
let Blue(Integer)
Red = 120
Green =180
Blue = 255
let R(Integer)
let G(Integer)
let B(Integer)
Message("SetColor Called")
prd.SetColor(Red, Green, Blue)
Message("GetColor Called")
prd.GetColor(R, G, B)
if( ( Red == R) and (Green == G) and ( Blue == B) )
{
Message("color set and get are equal ")
Message("color set ", Red ,Green , Blue)
Message("colorGet" ,R ,G , B)
}
else
{
Message("set color is different from get color ")
}
Raceway_Tray.SetDefaultBendRadius()
Raceway_Tray.SetDefaultBendRadius()
Signature
Raceway_Tray.SetDefaultBendRadius(iDefaultBendRadius : LENGTH) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iDefaultBendRadius |
In |
|
LENGTH |
Default bend radius value. |
Raceway_Tray.SetMinimunStraightLength()
Raceway_Tray.SetMinimunStraightLength()
Signature
Raceway_Tray.SetMinimunStraightLength(iMinimunStraightLength : LENGTH)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iMinimunStraightLength |
In |
|
LENGTH |
Minimum straight length value on the route.
|
Raceway_Tray.SetNodeBendRadius()
Raceway_Tray.SetNodeBendRadius()
Signature
Raceway_Tray.SetNodeBendRadius(iIndex : Integer, iRadius : LENGTH) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iIndex |
In |
|
Integer |
Node index at which user needs to set a bend
radius. |
iRadius |
In |
|
LENGTH |
Node bend radius value at existing node index.
|
Raceway_Tray.SetOpacity()
Raceway_Tray.SetOpacity()
Signature
Raceway_Tray.SetOpacity(iOpacity : Integer)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iOpacity |
In |
|
Integer |
- |
Raceway_Tray.SetSectionOrientation()
Raceway_Tray.SetSectionOrientation()
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
iEnumOrientation |
In |
|
RacewayOrientation |
CATRwyTrayVerticalUp, CATRwyTrayVerticalDown,
CATRwyTrayHorizontalLeft, CATRwyTrayHorizontalRight |
Raceway_Tray.SetShape()
Raceway_Tray.SetShape()
Signature
Raceway_Tray.SetShape(V_RwyShape_Enum : V_RwyShape_Enum)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
V_RwyShape_Enum |
In |
|
V_RwyShape_Enum |
Enum is already defined in metadata as U or H
shape type. |
Raceway_TrayXPort.CheckCompatibility()
Raceway_TrayXPort.CheckCompatibility()
Signature
Raceway_TrayXPort.CheckCompatibility(Port Owner Occurrence : ProductOccurrence, Second Port : VPMPort, Second Port Owner Occurrence : ProductOccurrence, Use Only Compatibility Rule Table : Boolean, List of Additional Specifications : List, Parameters whose check failed : List) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
Port Owner Occurrence |
In |
|
ProductOccurrence |
- |
Second Port |
In |
|
VPMPort |
- |
Second Port Owner
Occurrence |
In |
|
ProductOccurrence |
- |
Use Only Compatibility Rule
Table |
In |
|
Boolean |
- |
List of Additional
Specifications |
In |
|
List |
- |
Parameters whose check
failed |
Out |
|
List |
- |
Raceway_TrayXPort.SetPortAttributeString()
Raceway_TrayXPort.SetPortAttributeString()
Signature
Raceway_TrayXPort.SetPortAttributeString(AttrName : String, AttrValue : String)
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
AttrName |
In |
|
String |
- |
AttrValue |
In |
|
String |
- |
Raceway_Tray_Inst.PropagateReferenceToGeometry()
Launches PLM Update to propagate attribute, apply and update geometry
as per the shape and launch geometrical update. If any geometrical error appears,
then this method will try to correct the issue and for some issues, it returns the
error.
Signature
Raceway_Tray_Inst.PropagateReferenceToGeometry() : Integer
Important Note
Regarding the following functions:
- Add3Point()
- RemoveNode()
- GetNodeType()
- SetDefaultBendRadius()
- GetDefaultBendRadius()
- SetNodeBendRadius()
- GetNodeBendRadius()
- ResetNodeBendRadiustoDefault()
- SetMinimumStraightLength()
- GetMinimumStraightLength()
- PropagateReferenceToGeometry()
- SetNewReference()
If you call thiese functions, then only PLM attributes will be updated, but it
will not update the geometry, then it may cause or not check build break in the
geometry. After having completed all the modified routes functionality by
calling these functions, its user responsibility to call the
PropagateReferenceToGeometry() function at the end to update the geometry. This
function will correct bad values internally if it cause some build break or
other bad issues.
Raceway_Tray_Inst.SetNewReference()
Updates existing tray properties from raw material. It creates link
between tray and raw material. It copies material name from raw material to
tray.
Signature
Raceway_Tray_Inst.SetNewReference(VPMReference : VPMReference) : Integer
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
VPMReference |
In |
|
VPMReference |
VPMReference of the route filtered from the
Data Setup or provided by the user as input from which attributes need
to be copied. If input VPMReference is not NULL, then:
- NewFrom
-> Reuse or,
- NewFrom
-> ReuseorNewReference or
- NewFrom
-> NewReference
If input VPMReference is NULL, then NewFrom
-> NewReference
|
ReturnType
Integer
The
result values are as follows:
- 0: the method succeeds
- 1: the method failed
Raceway_Tray_Occurrence.GetTwistStatus()
Method used to detect if the tray contains bend points that cannot be
manufactured.
-
Signature
Raceway_Tray_Occurrence.GetTwistStatus() : Boolean
Raceway_Spool_Occurrence.GetSpoolMembers()
Method used to return the spool members.
Signature
Raceway_Spool_Occurrence.GetSpoolMembers() : List
Raceway_Spool_Occurrence.GetSpoolMode()
Method used to return the type of the spool in an enum. The enum type
is RacewaySpool_Mode.
You can initialize it to
RacewaySpool_Unknown. Depending on the state of the input spool,
the values returned can be one of the following:
- RacewaySpool_Preliminary
- RacewaySpool_Manufacturing
- RacewaySpool_Mix
- RacewaySpool_Invalid
Signature
Raceway_Spool_Occurrence.GetSpoolMode() : RacewaySpool_Mode
ReturnType
RacewaySpool_Mode
Raceway_Tray_Occurrence.GetAttributeOnConnectedPorts()
Method used to read the raceway attributes (lengths) on the connected
raceway parts.
Signature
Raceway_Tray_Occurrence.GetAttributeOnConnectedPorts(Linked Object : Raceway_Tray_Occurrence, Attribute : String, This Object Value : String, Linked Object Value : String) : Integer
Arguments
| Name |
Input / Output |
Required? |
Type |
Comment |
Linked Object |
In |
Yes |
Raceway_Tray_Occurrence |
|
Attribute |
In |
Yes |
String |
The list of attributes comes from the
Raceway_PartPort object. |
This Object Value |
Out |
Yes |
String |
|
Linked Object Value |
Out |
Yes |
String |
|
Raceway_Tray_Occurrence.GetAttributeOnConnectedPorts()
Method used to read the attributes (lengths) on the connected raceway
trays.
Signature
Raceway_Tray_Occurrence.GetAttributeOnConnectedPorts(Linked Object : Raceway_Tray_Occurrence, Attribute : String, This Object Value : LENGTH, Linked Object Value : LENGTH) : Integer
Arguments
| Name |
Input / Output |
Required? |
Type |
Comment |
Linked Object |
In |
Yes |
Raceway_Tray_Occurrence |
|
Attribute |
In |
Yes |
String |
The list of attributes comes from the
Raceway_PartPort object. |
This Object Value |
Out |
Yes |
LENGTH |
|
Linked Object Value |
Out |
Yes |
LENGTH |
|
Raceway_Tray_Occurrence.GetRelatedObjects()
Method used to return the connected objects.
SharedEquipmentPart.CreateRacewayReplicatePort()
Lets
you replicate Raceway ports.
VPMReference.CreateRacewayPortOnReference()
Signature
VPMReference.CreateRacewayPortOnReference(PortPtOrigin : GSMPoint, AlignDir : Direction, OrientDir : Direction, PortType : RacewayPort_Types, PortName : String, OffsetPt : GSMPoint]) : Raceway_PartPort
Arguments
| Name |
Input/Output |
Required? |
Type |
Comment |
PortPtOrigin |
In |
|
GSMPoint |
- |
AlignDir |
In |
|
Direction |
- |
OrientDir |
In |
|
Direction |
- |
PortType |
In |
|
RacewayPort_Types |
- |
PortName |
In |
|
String |
- |
OffsetPt |
In |
|
GSMPoint |
- |
ReturnType
Raceway_PartPort
Example
let prd(VPMReference)
let pGSMPoint_1(GSMPoint)
let pGSMPoint_2(GSMPoint)
let pGSMPointCoord(GSMPointCoord)
let DirectionAlign(Direction)
let DirectionOrient(Direction)
let pPoint(Point)
let pPointOffset(Point)
let pPointType(PointType)
let pBody(BodyFeature)
pPointType = "Coordinates"
let NameProduct(String)
NameProduct = prd.Name
if("Physical Product00000002_95E5D97B-0000-1C0C-5E0DB5C000044475" == NameProduct)
{
pBody = prd->Find ("BodyFeature","",TRUE)
if (NULL <> pBody)
{
Trace(1, " Body retrieved : ",pBody.Name)
let porttype(RacewayPort_Types)
/* 2 point Hole Port, + Offset */
/* ============================*/
porttype = "CATRaceway2HolePort"
portName = "RCD_Port_40_2pHole_+Offset"
SetWorkingContext(pBody)
let port(Raceway_Port)
pPoint = pBody->Find("Point","x.Name==\"Point_1\"",TRUE)
set pGSMPoint_1 = pPoint
if (NULL <> pGSMPoint_1)
{
pGSMPoint_1.PointType = pPointType
set pGSMPointCoord = pGSMPoint_1
pGSMPointCoord.X = 0mm
pGSMPointCoord.Y = 0mm
pGSMPointCoord.Z = 0mm
pGSMPointCoord.Update()
}
pPoint = pBody->Find("Point","x.Name==\"Point_2\"",TRUE)
set pGSMPoint_2 = pPoint
if (NULL <> pGSMPoint_2)
{
pGSMPoint_2.PointType = pPointType
set pGSMPointCoord = pGSMPoint_2
pGSMPointCoord.X = 100mm
pGSMPointCoord.Y = 0mm
pGSMPointCoord.Z = 0mm
pGSMPointCoord.Update()
}
DirectionAlign = direction(1mm, 0mm, 0mm)
DirectionOrient = direction(0mm, 0mm, 1mm)
port = prd.CreateRacewayPortOnReference(pGSMPoint_1, DirectionAlign, DirectionOrient, porttype, portName, pGSMPoint_2)
if (NULL == port )
{
Message("Creation FAIL")
}
pBody.Update()
}
}
|