Remove-Appx
Volume
Syntax
Remove-AppxVolume
[-Volume] <AppxVolume[]>
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Remove-AppxVolume cmdlet removes an AppxVolume . You can only remove a volume after there are no apps staged to it for any user. After you remove a volume, apps can no longer be added to it.
Examples
Example 1: Remove a volume by using an ID
PS C:\> Remove-AppxVolume -Volume {984786d3-0cae-49de-a68f-8bedb0ca260b}
This command removes a volume that has the specified media ID.
Example 2: Remove a volume by using a path
PS C:\> Remove-AppxVolume -Volume E:\
This command removes a volume at the path E:.
Required Parameters
Specifies the AppxVolume object to remove.
| Type: | AppxVolume[] |
| Position: | 1 |
| Default value: | None |
| Accept pipeline input: | True (ByPropertyName, ByValue) |
| Accept wildcard characters: | False |
Optional Parameters
Prompts you for confirmation before running the cmdlet.
| Type: | SwitchParameter |
| Aliases: | cf |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Shows what would happen if the cmdlet runs. The cmdlet is not run.
| Type: | SwitchParameter |
| Aliases: | wi |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |