powershellscripts.com

Tutorials  PowerShell Cmdlet Help for Remove-VIProperty



NAME
Remove-VIProperty

SYNOPSIS
Removes the extended properties from the specified object types.

SYNTAX
Remove-VIProperty [-VIProperty] [-WhatIf] [-Confirm] []

Remove-VIProperty [-Name] [-ObjectType] [-WhatIf] [-Confirm] []


DESCRIPTION
Removes the extended properties from the specified object types. Changes take effect upon the next retrieval of the
corresponding objects.


PARAMETERS
-VIProperty
Specify the extended object properties you want to remove.

Required? true
Position? 1
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? false

-WhatIf
Indicate that the cmdlet is run only to display the changes that would be made and actually no objects are modi
fied.

Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false

-Confirm
If the value is $true, indicates that the cmdlet asks for confirmation before running. If the value is $false,
the cmdlet runs without asking for user confirmation.

Required? false
Position? named
Default value $true
Accept pipeline input? false
Accept wildcard characters? false

-Name
Specify the names of the extended properties you want to remove.

Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? true

-ObjectType
Specify the object types to which the extended properties you want to remove belong.

Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? true


This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer and OutVariable. For more information, type,
"get-help about_commonparameters".

INPUTS



OUTPUTS
none


NOTES




-------------- Example 1 --------------

C:\PS>Remove-VIProperty -Name * -ObjectType *


Removes all custom properties.





-------------- Example 2 --------------

C:\PS>Remove-VIProperty -Name * -ObjectType VirtualMachine


Removes all custom properties for the VirtualMachine object type.





-------------- Example 3 --------------

C:\PS>Remove-VIProperty -Name OverallStatus, ConfigStatus -ObjectType VirtualMachine


Removes the OverallStatus and ConfigStatus for the VirtualMachine object type.





-------------- Example 4 --------------

C:\PS>Remove-VIProperty -Name OverallStatus -ObjectType VirtualMachine, Datacenter


Removes the OverallStatus property for the VirtualMachine and Datacenter types.





-------------- Example 5 --------------

C:\PS>Remove-VIProperty -Name *status* -ObjectType Virt*


Removes all properties that contain "status" in their names for object types with names that start with "Virt".






RELATED LINKS
Online version: http://www.vmware.com/support/developer/PowerCLI/PowerCLI501/html/Remove-VIProperty.html
New-VIProperty
Get-VIProperty