This collection is currently managed by a CATIAMaterialDocument object.
Methods
- Func Add() As
- Adds a new material family to the MaterialFamilies collection.
FileToOpen = "e:\users\ast\materials\Catalog.CATMaterial" Dim MyDocument As MaterialDocument Set MyDocument = Documents.Open(FileToOpen) Dim MyMaterialFamily As MaterialFamily Set MyMaterialFamily = MyDocument.MaterialFamilies.Add
- Parameters:
-
- iIndex
- The index of the material family to retrieve in the collection of material families. Compared with other collections, you cannot use the name of the material family as argument. dd>
- Returns:
- The retrieved material family
Dim MyMaterialFamily As MaterialFamily Set MyMaterialFamily = MaterialFamilies.Item(6)dd>
- Parameters:
-
- iIndex
- The index of the material family to remove. Compared with other collections, you cannot use the name of the material family as argument.
- Example:
-
The following example removes the second material family
in the collection attached to the active document.
This document must be a
object.
FileToOpen = "e:\users\ast\materials\Catalog.CATMaterial" Dim MyDocument As MaterialDocument Set MyDocument = Documents.Open(FileToOpen) MyDocument.MaterialFamilies.Remove(2)
dd>