Remove Method (PIContexts collection)

                

 

Removes an existing PIContext from a server.

 

Syntax

object.Remove ContextName

The Remove method syntax has these parts:

Part

Description

object

An object expression that evaluates to a PIContexts collection.

ContextName

A string naming the context to be removed.

 

Remarks

Users who have previously been assigned the context that is removed are assigned the "default" context. There is a single default context string that cannot be removed but can be renamed. Initially the context is called "default".

 

Trappable Errors

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

Error

Description

pseACCESSDENIED

Caller does not have sufficient privilege to remove a PIContext.

pseNOEMPTYSTRINGS

The specified context name can not be empty or all blanks.

pseCONTEXTNOTFOUND

The specified context name does not exist on the server.

pseCONTEXTREMOVE

Unable to remove the context from the server.

Enabling Operational Intelligence