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

PI Powershell

NewAFCheckOut Class

  • Last UpdatedDec 15, 2025
  • 3 minute read
NewAFCheckOut Class

Check out AF Objects on an AF Server

The New-AFCheckOut cmdlet explicitly checks out the specified AF objects on an AF Server.

Inheritance Hierarchy

SystemObject
  InternalCommand
    Cmdlet
      PSCmdlet
        OSIsoft.PowerShellOSICmdletBase
          OSIsoft.PowerShellNewAFCheckOut

Namespace:  OSIsoft.PowerShell
Assembly:  OSIsoft.PowerShell (in OSIsoft.PowerShell.dll) Version: 3.1.1.0 (3.1.1.466)

Syntax

[CmdletAttribute("New", "AFCheckOut", SupportsShouldProcess = true)]
public class NewAFCheckOut : OSICmdletBase
<CmdletAttribute("New", "AFCheckOut", SupportsShouldProcess := true)>
Public Class NewAFCheckOut
	Inherits OSICmdletBase

Dim instance As NewAFCheckOut
[CmdletAttribute(L"New", L"AFCheckOut", SupportsShouldProcess = true)]
public ref class NewAFCheckOut : public OSICmdletBase
[<CmdletAttribute("New", "AFCheckOut", SupportsShouldProcess = true)>]
type NewAFCheckOut =  
    class
        inherit OSICmdletBase
    end

The NewAFCheckOut type exposes the following members.

Constructors

  NameDescription
Public method
NewAFCheckOut

Properties

  NameDescription
Public property
ItemToCheckOut

AF Objects to check out. Can pass more than one object as an array of comma separated values

Public property
PassThru

Returns objects that were changed. By default, this cmdlet does not generate any output

Examples

New-AFCheckOut -ItemsToCheckOut (Get-AFElement -Name Boiler1 -AFDatabase $afDB)

Where:

$afDB = Get-AFDatabase -Name "AFDatabase1" -AFServer (Get-AFServer -Name "PIAF1")

Explicitly checks out the top level element "Boiler1" on the AF Database "AFDatabase1" on the AF Server "PIAF1".

Examples

$MyCheckedOutElement = New-AFCheckOut -ItemsToCheckOut (Get-AFElement -Name Boiler1 -AFDatabase $afDB) -PassThrough

Where:

$afDB = Get-AFDatabase -Name "AFDatabase1" -AFServer (Get-AFServer -Name "PIAF1")

Explicitly checks out the top level element "Boiler1" on the AF Database "AFDatabase1" on the AF Server "PIAF1". The object which is checked out is returned by the cmdlet and stored in variable $MyCheckedOutElement for further use.

Examples

New-AFCheckOut -ItemsToCheckOut $MyAFElements

Where:

$afDB = Get-AFDatabase -Name "AFDatabase1" -AFServer (Get-AFServer -Name "PIAF1")

$MyAFElements = Get-AFElement -Name * -AFDatabase $afDB

Explicitly checks out all top level elements on the AF Database "AFDatabase1" on the AF Server "PIAF1".

See Also

TitleResults for “How to create a CRG?”Also Available in