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

AF SDK Reference

PIServers.RemoveAt Method

  • Last UpdatedNov 18, 2025
  • 2 minute read
PIServers.RemoveAt Method
Unregisters an existing PIServer by removing the entry from the list of known PI Data Archive servers on the local machine.

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

Syntax

public void RemoveAt(
	int index
)
Public Sub RemoveAt ( 
	index As Integer
)

Dim instance As PIServers
Dim index As Integer

instance.RemoveAt(index)
public:
virtual void RemoveAt(
	int index
) sealed
abstract RemoveAt : 
        index : int -> unit 
override RemoveAt : 
        index : int -> unit 

Parameters

index
Type: SystemInt32
Specifies the position number of a member of the collection. The range is between 0 and one less than the value of the collection's Count property.

Implements

IListTRemoveAt(Int32)
IListRemoveAt(Int32)

Exceptions

ExceptionCondition
InvalidOperationException This exception is thrown if an attempt is made to remove the last PIServer in the list.

Remarks

This method is used to unregisters an existing PIServer entry from the list of known PI Data Arhive servers on the local machine. This does not affect the configuration of servers on other client computers.
Important note Important
The last PIServer in the list is not allowed to be removed.

Version Information

AFSDK


See Also

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