KnowledgeInterfaces OptimizationConstraints (Collection)
All Frameworks Object Hierarchy This Framework Indexes
OptimizationConstraints (Collection)
Represents a collection of Optimization Constraint.
Method Index
-
AddConstraint
- Adds a optimization constraint.
-
Item
- Returns an optimization constraint using its index or its name from the
optimization constraints collection.
-
RemoveConstraint
- Removes a given optimization constraint using its index or its name from the optimization constraints collection.
Methods
o Func AddConstraint( | | constraintExpression) As |
-
Adds a optimization constraint. This parameter must not be read only.
-
Returns an optimization constraint using its index or its name from the
optimization constraints collection.
- Parameters:
-
- iIndex
- The index or the name of the optimization constraint to retrieve from
the collection of optimization constraints.
As a numerics, this index is the rank of the optimization constraint
in the collection.
The index of the first optimization constraint in the collection is 1, and
the index of the last optimization constraint is Count.
As a string, it is the name you assigned to the optimization constraint using
the
AnyObject.Name property or when changing the optimization constraint name by the property panel.
- Returns:
- The retrieved optimization constraint
- Example:
-
This example retrieves the last optimization constraint in the optimization constraints
collection.
Set lastConstraint = constraints.Item(constraints.Count)
o Sub RemoveConstraint( | | iIndex) |
-
Removes a given optimization constraint using its index or its name from the optimization constraints collection.
- Parameters:
-
- iIndex
- the name of the constraint if argument is a string or the index of the constraint if argument is an integer.
Copyright © 2003, Dassault Systèmes. All rights reserved.