|
-
Create a Part containing 3 points.
-
From the Start > Knowledgeware menu, access
the Knowledge Advisor workbench.
-
Click the List icon ()
to create the list that will contain the created points.
-
Add a formula to fill in the list.
- Click the Formula Editor icon. The Formula Editor is
displayed. In the specification tree, select List.1 and click
Add formula.
|
- List.1=PartBody.Query("Point",""). Click OK twice
when done.
|
|
Note that Japanese
users must type the following formula. |
|
-
Click the Reaction icon ().
The Reaction dialog box opens.
|
- In the Source type field, select Selection
and select the list in the specification tree for the Reaction to
be applied when the list is modified.
- In the Select a source... dialog box, select List.1 and click
OK.
|
- In the Available events list, select
ValueChange.
|
- In the Action field, select Knowledgeware
action and enter the following message action body.
let x(Point)
for x inside parameter
{
if (x.GetAttributeReal("Z") < 0.02)
x.SetAttributeReal("Z",0.02)
} |
- Click OK when done. The Reaction feature is added to
the Relations node.
|
-
Click the Reaction icon ().
The Reaction dialog box opens.
|
- In the Source type field, select Selection
and select the list in the specification tree for the Reaction to
be applied when the list is modified.
- In the Select a source... dialog box, select List.1
and click OK.
|
- In the Available events list, select
ValueChange.
|
In the Action field, select
Knowledgeware action and enter the following message action
body.
let i = 1
let x(Point)
for i while i<=parameter.Size()
{
x = parameter.GetItem(i)
if (x.GetAttributeReal("Y") < 0.04)
x.SetAttributeReal("Y",0.04)
} |
- Click OK when done. The Reaction feature is added to
the Relations node.
|
-
Create a point with the following coordinates:
-
Update the Part twice: The Y and Z coordinates are set to
40 and 20 mm. Click here
to display the result sample.
|