How to disable Alerts in SharePoint list using Powershell in Office 365/SharePoint 2010/2013/2016?
Hello SharePointers
Below is the Powershell used to disableĀ Alerts in SharePoint list using Powershell in Office 365/SharePoint 2010/2013/2016
$url = ‘https://warnerbros.sharepoint.com/sites/TS/’
$listTitle = ‘Testlist’
$setstatus = [Microsoft.SharePoint.SPAlertStatus]::Off
$web = Get-SPWeb $url
$list = $web.Lists[$listTitle]
$web.Alerts | ? { $_.List.ID -eq $list.ID } | % {
$_.Status = $setstatus
$_.Update()
}
Happy SharePointing Folks š