PISystem.CheckIn Method (AFCheckedOutMode)
- Last UpdatedNov 18, 2025
- 3 minute read
- PI System
- AF SDK 2024 R2
- Developer
Namespace: OSIsoft.AF
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public void CheckIn( AFCheckedOutMode mode )
Public Sub CheckIn ( mode As AFCheckedOutMode ) Dim instance As PISystem Dim mode As AFCheckedOutMode instance.CheckIn(mode)
public: void CheckIn( AFCheckedOutMode mode )
member CheckIn : mode : AFCheckedOutMode -> unit
Parameters
- mode
- Type: OSIsoft.AFAFCheckedOutMode
The mode specifies which objects will be checked in. Specifying ObjectsCheckedOutToMe is the same as calling the CheckIn method with no parameters.
Events
| Event Type | Reason |
|---|---|
| PISystemChanged | This event will be raised for each object updated by this method call. |
Remarks
This method checks in (commits) all the changes to all modified objects at the system level by saving the object's information to persistent storage according to the specified AFCheckedOutMode. The modified system level AFContact, AFNotificationContactTemplate, and UOMDatabase objects will be saved to persistent storage. Any objects checked out under an AFDatabase will not be saved. If this PISystem is an AFCollective, then any changes to the Collective will also be saved to the server.
Before an object's configuration can be modified, it must be locked by checking it out for modifications by calling the CheckOut method of the object. After making changes, the modifications are saved permanently by calling this method or the CheckIn method of the object. Alternatively, modifications can be stored into the server temporarily for this user by calling either the ApplyChanges(AFCheckedOutMode) or the ApplyChanges method of the object. Changes to system level objects are not persisted to the server until they are either Applied or CheckedIn. All changes to the system level objects by the current user can also be undone by calling the UndoCheckOut(Boolean) method.
Care should be taken to limit the amount of changes checked in at one time to reasonable amounts. While it is possible to make a significant number of changes at one time, these changes are transferred to the PI AF Server at one time and can thus require significant amounts of memory to complete the operation.
When checking in a large number of items and an error occurs during the check in, some objects may have been successfully checked in without the SDK knowing. When this occurs you will get an error that the object is not checked out on the next check in attempt. If this occurs, you can call Refresh Overload to update the SDK's list of successfully checked in objects.