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

PI Powershell

RemoveAFAttribute Class

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

Remove an AF Attribute

The Remove-AFAttribute cmdlet removes an existing AF Attribute. The attribute to remove can be an attribute on an AF Element, or an AF Sub Attribute

Inheritance Hierarchy

SystemObject
  InternalCommand
    Cmdlet
      PSCmdlet
        OSIsoft.PowerShellOSICmdletBase
          OSIsoft.PowerShellRemoveAFAttribute

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

Syntax

[CmdletAttribute("Remove", "AFAttribute", DefaultParameterSetName = "Attribute", 
	SupportsShouldProcess = true)]
public class RemoveAFAttribute : OSICmdletBase
<CmdletAttribute("Remove", "AFAttribute", DefaultParameterSetName := "Attribute", 
	SupportsShouldProcess := true)>
Public Class RemoveAFAttribute
	Inherits OSICmdletBase

Dim instance As RemoveAFAttribute
[CmdletAttribute(L"Remove", L"AFAttribute", DefaultParameterSetName = L"Attribute", 
	SupportsShouldProcess = true)]
public ref class RemoveAFAttribute : public OSICmdletBase
[<CmdletAttribute("Remove", "AFAttribute", DefaultParameterSetName = "Attribute", 
	SupportsShouldProcess = true)>]
type RemoveAFAttribute =  
    class
        inherit OSICmdletBase
    end

The RemoveAFAttribute type exposes the following members.

Constructors

  NameDescription
Public method
RemoveAFAttribute

Properties

  NameDescription
Public property
AFAttribute

Name of the parent AF Attribute from which to delete the AF Sub Attribute

Public property
AFElement

Name of the AF Element from which to delete the AF Attribute

Public property
CheckIn

Check in changes immediately

Public property
ID

ID of the AF Attribute to delete

Public property
Name

Name of the AF Attribute to delete

Examples

Remove-AFAttribute -Name "Interior Temperature" -CheckIn -AFElement $afElement

Where:

$afElement = Get-AFElement -Name "Anneal Oven 1" -AFDatabase (Get-AFDatabase -Name "AFDatabase1" -AFServer (Get-AFServer -Name "PIAF1"))

Deletes the AF Attribute "Interior Temperature" on the top level element "Anneal Oven 1" on the database "AFDatabase1" on the AF Server "PIAF1". The changes are immediately checked in.

Examples

Remove-AFAttribute -Name "Temperature (F)" -CheckIn -AFAttribute $afAttribute

Where:

$afElement = Get-AFElement -Name "Anneal Oven 1" -AFDatabase (Get-AFDatabase -Name "AFDatabase1" -AFServer (Get-AFServer -Name "PIAF1"))

$afAttribute = Get-AFAttribute -Name "Interior Temperature" -AFElement $afElement

Deletes the AF Sub Attribute "Temperature (F)" from the AF Attribute "Interior Temperature" on the top level element "Anneal Oven 1" on the database "AFDatabase1" on the AF Server "PIAF1". The changes are immediately checked in.

See Also

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