Remove Method (PIUnitBatches collection)

             

Removes passed PIUnitBatch from this collection. Also removes the PIBatch reference from the PIUnitBatch.

 

Syntax

object.Remove varPIUnitBatch

The Remove method syntax has these parts:

Part

Description

object

An object expression that evaluates to a PISubBatches collection.

varPIUnitBatch

Variant which represents the PIUnitBatch object to remove.

 

Remarks

The argument varPIUnitBatch may be the PIUnitBatch object or the UniqueID of the PIUnitBatch object to remove from the collection. This method only removes the PIUnitBatch from the collection, it is not permanently removed from the server database.

The PIUnitBatch.PIBatch property is never directly set. Adding a PIUnitBatch to the PIBatch.PIUnitBatches collection implicitly sets the PIUnitBatch.PIBatch property. Removing a PIUnitBatch from the PIBatch.PIUnitBatches collection implicitly sets the PIUnitBatch.PIBatch property to Nothing.

 

Trappable Errors

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

Error

Description

pseNOGENSERVER

The parent underlying generic server object could not be retrieved.

 

Enabling Operational Intelligence