MTMerge Method (MTNVS collection)

             

 

Merges another MTNVS collection into this one, by copying its members.

 

Syntax

object.MTMerge Source, ReplaceDuplicates

The MTMerge method syntax has these parts:

Part

Description

object

An object expression that evaluates to a MTNVS collection.

Source

An expression that evaluates to a MTNVS collection. Each member of the source collection is copied, and the copies are added to the collection.

ReplaceDuplicates

An optional Boolean expression, as described in Settings.

 

Settings

The settings for ReplaceDuplicates are:

Settings

Description

true

If the collection previously contained any MTNV with the same name as any members of the source collection, the values taken from the source collection replace the old values. This is the default.

false

If the collection previously contained any MTNV with the same name as any members of the source collection, the old value remains unchanged and an error is reported.

 

Trappable Errors

In addition to generic errors (such as Out of Memory), the following errors may occur:

Error

Description

pseACCESSDENIED

The collection cannot be modified because it is frozen; that is, the collection's MTReadOnly property is true.

pseDUPLICATENAME

The source collection contains one or more items with the same names as members of this collection, but ReplaceDuplicates is false. All items whose names are not duplicates are merged.

Enabling Operational Intelligence