Remove Method (StateSets collection)

                

 

Removes a StateSet from the StateSets collection. The call makes the StateSet inaccessible on the Server as well as removing it from the in memory StateSets collection.

 

Syntax

object.Remove Name

The Remove method syntax has these parts:

Part

Description

object

An object expression that evaluates to a StateSets collection.

Name

A string containing the name of an existing StateSet to remove.

 

Remarks

Removing a StateSet can be problematic. Archived data may retain references to digital states from the set being removed rendering their future display problematic. The response of the Server to this method may vary depending on Server version. For example PI 2.x servers do not support this function, PI3.x servers will rename the StateSet rather than removing it completely.

 

Trappable Errors

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

Error

Description

pseLOADSTATESETS

Unable to load the existing collection of StateSets from the server.

pseSTATESETNOTFOUND

The requested StateSet was not found on the server.

pseNOGENSERVER

The parent underlying generic server object could not be retrieved.

pseREMOVESTATESET

Unable to remove the StateSet from the server. The error description will contain more information regarding the problem.

Enabling Operational Intelligence