| To enable alerts for Web application we use below code
$SPwebapp=Get-SPWebApplication "http://SharePointSite.com"
$SPwebapp.AlertsEnabled = $true
$SPwebapp.Update()
# To Disable alerts for a Web application
$SPwebapp.AlertsEnabled = $false
$SPwebapp.Update | | |