All Frameworks  Object Hierarchy  This Framework  Indexes   

Groups (Collection)

A collection of all groups currently managed by the application.

The method Product.GetTechnologicalObject ("Groups") on the root product retrieves this collection.


Method Index

AddFromSel
Creates a Group containing all products in the selection and adds it to the Groups Collection.
Add
Creates an empty Group and adds it to the Groups Collection.
AllLeaves
Returns a group which contains all the terminal nodes of the current root product.
Item
Returns a group using its index or its name from the Groups collection.
Remove
Removes a group from the Groups collection.

Methods


o Func AddFromSel() As
Creates a Group containing all products in the selection and adds it to the Groups Collection.
Returns:
The created group
Example:
This example creates a new group containing all products in the selection in the TheGroups collection.
    Dim NewGroup As Group
    Set NewGroup = TheGroups.AddFromSel
    
o Func Add() As
Creates an empty Group and adds it to the Groups Collection.
Returns:
The created group
Example:
This example creates a new group in the TheGroups collection.
    Dim NewGroup As Group
    Set NewGroup = TheGroups.Add
    
o Func AllLeaves() As
Returns a group which contains all the terminal nodes of the current root product.
Example:
This example retrieves the group in the TheGroups collection.
    Dim AllLeavesGroup As Group
    Set AllLeavesGroup = TheGroups.AllLeaves
    
o Func Item( iIndex) As
Returns a group using its index or its name from the Groups collection.
Parameters:
iIndex
The index or the name of the Group to retrieve from the collection of groups. As a numerics, this index is the rank of the Group in the collection. The index of the first Group in the collection is 1, and the index of the last Group is Count. As a string, it is the name you assigned to the Group.
Returns:
The retrieved Group
Example:
This example retrieves in ThisGroup the ninth Group, and in ThatGroup the Group named Group3 from the TheGroups collection.
    Dim ThisGroup As Group
    Set ThisGroup = TheGroups.Item(9)
    Dim ThatGroup As Group
    Set ThatGroup = TheGroups.Item("Group3")
    
o Sub Remove( iIndex)
Removes a group from the Groups collection.
Parameters:
iIndex
The index or the name of the Group to retrieve from he collection of groups. As a numerics, this index is the rank of the Group in the collection. The index of the first Group in the collection is 1, and the index of the last Group is Count. As a string, it is the name you assigned to the Group.
Example:
The following example removes the tenth Group and the Group named Group2 from the TheGroups collection.
    TheGroups.Remove(10)
    TheGroups.Remove("Group2")
    

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