CIMTranslationGroup.Key (property)

Gets the Key value.
Syntax: String = object.Key
object.Key = String
Description: Gets and Sets the Key value of the group. This will fail if another CIMTranslationGroup is already using the new key value.


Sub Key_Example()
    Dim oLangMap As CIMLangMapper.CIMLangMap
    Dim oTranslationGroup As CIMLangMapper.CIMTranslationGroup
    Set oLangMap = CreateObject("CIMLangMapper.CIMLangMap")
    oLangMap.Load "c:\trans.clm"
    Set oTranslationGroup = oLangMap.LookupTranslationGroup("Wheel bearing")
    if Not oTranslationGroup Is Nothing Then
      oTranslationGroup.Key ="Wheel ball bearings"
    End If
    Set oTranslationGroup = oLangMap.LookupTranslationGroup("Wheel ball bearings")
    if Not oTranslationGroup Is Nothing Then
      MsgBox oTranslationGroup.Key
    End If
End Sub