| external help file | Microsoft.Online.SharePoint.PowerShell.dll-Help.xml |
|---|---|
| Module Name | Microsoft.Online.SharePoint.PowerShell |
| online version | https://learn.microsoft.com/powershell/module/microsoft.online.sharepoint.powershell/remove-spocontainer |
| applicable | SharePoint Online |
| title | Remove-SPOContainer |
| schema | 2.0.0 |
| author | cindylay |
| ms.author | cindylay |
| ms.reviewer |
Sends a Container to the Recycle Bin.
Remove-SPOContainer [-Identity] <SPOContainerPipeBind> [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
The Remove-SPOContainer cmdlet deletes a File Storage Container and puts it in the Recycle Bin. A Container that is deleted will no longer be retrieved by the Get-SPOContainer cmdlet.
When admins delete a Container, it is moved into the Recycle Bin. A deleted Container can be restored from the Recycle Bin within 93 days. If a Container is deleted from the Recycle Bin, or it exceeds the 93-day retention period, it is permanently deleted. Deleting a Container deletes everything within it, including all documents and files. You can view all deleted Containers in the Recycle Bin with the Get-SPODeletedContainer cmdlet.
You must be at least a SharePoint Online administrator to run the cmdlet.
Remove-SPOContainer -Identity 423poi45-jikl-9bnm-b302-1234ghy56789Example 1 places the Container with the ContainerId 423poi45-jikl-9bnm-b302-1234ghy56789 into the Recycle Bin. The Container will be permanently deleted from the Recycle Bin after 93 days unless the deleted Container is restored before permanent deletion.
Applicable: SharePoint Online
Whether to remove the container without prompting for confirmation.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseApplicable: SharePoint Online
Use this parameter to provide the ContainerId of the Container to be deleted.
Type: Microsoft.Online.SharePoint.PowerShell.SPOContainerPipeBind
Parameter Sets: (All)
Aliases:
Required: True
Position: 0
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalsePrompts you for confirmation before running the cmdlet.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseShows what would happen if the cmdlet runs. The cmdlet is not run.
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.