Merge Method (PIUsers collection)

               

 

The Merge method is passed an existing PIUsers collection (typically from another Server) and adds the users to the current Server.PIUsers collection.

 

Not Implemented

 

Syntax

object.Merge NewUsers, MergeFlag, nvErrors

The Merge method syntax has these parts:

Part

Description

object

An object expression that evaluates to a PIUsers collection.

NewUsers

A PIUsers collection containing users to be added to the Server

MergeFlag

A flag indicating how the merge is to be performed (see Settings below for possible values).

nvErrors

A reference to a NamedValues collection which is used to return errors. When a Merge is executed it may only be partly successful. The nvErrors collection contains a NamedValue object for each user that was not added to the server. The object’s name is that of the user and the value is an error constant.

 

Settings

The settings for MergeFlag are:

Setting

Description

mrgIgnoreDuplicates

If the passed collection contains a PIUser with the same name as an existing PIUser, that passed PIUser is not added and no error is indicated.

mrgFlagDuplicates

If the passed collection contains a PIUser with the same name as an existing PIUser, an error is reported in the nvErrors collection for that user.

Enabling Operational Intelligence