Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AF SDK Reference

IAFNamedCollection(T).Remove Method (Guid)

  • Last UpdatedNov 18, 2025
  • 2 minute read
IAFNamedCollection(T).Remove Method (Guid)
Removes the item with the specified id from the collection.

Namespace:  OSIsoft.AF
Assembly:  OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182

Syntax

bool Remove(
	Guid id
)
Function Remove ( 
	id As Guid
) As Boolean

Dim instance As IAFNamedCollection
Dim id As Guid
Dim returnValue As Boolean

returnValue = instance.Remove(id)
bool Remove(
	Guid id
)
abstract Remove : 
        id : Guid -> bool 

Parameters

id
Type: SystemGuid
The id of the item to remove.

Return Value

Type: Boolean
Returns if the item is successfully removed; otherwise, . This method also returns if id was not found in the original collection.

Remarks

This method removes the item from the collection with the specified id. The id of the item is also removed from the lookup dictionary. This method approaches an O(1) operation.

If there is a need to delete many objects at once, it is better to delete them in bulk by using the delete method with a specified list of ids.

Version Information

AFSDK


See Also

In This Topic
Related Links
TitleResults for “How to create a CRG?”Also Available in