Indexes   

Relation (Object)

Represents the relation object.
It is an abstract object which is not intended to be created as such, but from which the check, design table, formula, rule, objects derive.
See also:
Check, DesignTable, Formula, Rule

Property Index

Comment
Returns or sets the comment associated with the relation.
Context
Returns the context of the parameter.
NbInParameters
Returns the number of input parameters of the relation.
NbOutParameters
Returns the number of output parameters of the relation.
Value
Returns the definition of the relation.

Method Index

GetInParameter
Returns an input parameter of the relation.
GetOutParameter
Returns an output parameter of the relation.
Modify
Modifies the relation.
Rename
Renames the relation.

Properties


o Property Comment() As
Returns or sets the comment associated with the relation. The comment explains the relation's purpose. It is passed as the second input argument of the relation creation methods of the Relations collection.
Example:
This example retrieves the maximummass relation comment and displays it in a message box:
 relcomment = maximummass.Comment
 MsgBox "maximummass comment : " & relcomment
 
o Property Context() As (Read Only)
Returns the context of the parameter.
The context of a parameter can be a part, a product, a drafting, or a process document, depending where the parameter is.
Returns:
The context
See also:
Part, Product, CATIADrawing, CATIAProcess
o Property NbInParameters() As (Read Only)
Returns the number of input parameters of the relation.
o Property NbOutParameters() As (Read Only)
Returns the number of output parameters of the relation.
The output parameters of the relation are those constrained by the relation.
o Property Value() As (Read Only)
Returns the definition of the relation. It returns an empty string if the relation is not an expressional one (for example for a design table). The definition is the body to be executed to compute one or several parameters. It is passed as the last input argument of the relation creation methods of the Relations collection.
Example:
This example retrieves the maximummass relation definition and displays it in a message box:
 reldef = maximummass.Value
 MsgBox "maximummass relation is defined as " & reldef
 

Methods


o Func GetInParameter( iIndex) As
Returns an input parameter of the relation.
This method can return an object that is not a parameter, that is, you cannot handle it as a Parameter object. For example, in a relation like
Area.1 = area(PartBody\Pad.1\Sketch.1)
the object PartBody\Pad.1\Sketch.1 is a sketch and not a parameter.
To use such an object, call the Visual Basic TypeName function to retrieve its real type.
Dim objectType
 objectType = TypeName(oParameter)
 If objectType = "Parameter" Then
 ...
Parameters:
iIndex
The searched input parameter index in the relation.
Legal values: 1 ≤ iIndex ≤
NbInParameters
o Func GetOutParameter( iIndex) As
Returns an output parameter of the relation. Use TypeName method on the returned parameter to get the real type of the parameter.
Parameters:
iIndex
The searched input parameter index in the relation.
Legal values: 1 ≤ iIndex ≤
NbOutParameters
o Sub Modify( iValue)
Modifies the relation.
Parameters:
iValue
The new relation value
o Sub Rename( iName)
Renames the relation.
Parameters:
iName
The new relation name

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