PIServers.Add Method
- Last UpdatedNov 18, 2025
- 2 minute read
- PI System
- AF SDK 2024 R2
- Developer
Registers a new PIServer to the list of known servers on the local machine.
Namespace: OSIsoft.AF.PI
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public PIServer Add( string name )
Public Function Add ( name As String ) As PIServer Dim instance As PIServers Dim name As String Dim returnValue As PIServer returnValue = instance.Add(name)
public: PIServer^ Add( String^ name )
member Add : name : string -> PIServer
Parameters
- name
- Type: SystemString
The name of the desired name for the PIServer as it is known on the local machine. This name must be unique from all other local PIServer names on the local machine. See the ValidateName(String, String) method for a description of what is valid when setting the name of the object.
Return Value
Type: PIServerReturns the newly created PIServer object.
Remarks
This method is used to add an entry to the list of known PI Data Archive servers on the local machine.