Tech
News
Videos
Forums
Jobs
Books
Events
More
Interviews
Live
Learn
Training
Career
Members
Blogs
Challenges
Certification
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
Enabling Alerts in SharePoint 2013 - PowerShell Commands
WhatsApp
Lakshmanan Sethu Sankaranarayan
10y
8.3
k
0
0
25
Blog
Lets say you have a SharePoint group named "Notify Members". They would like to receive an alert when a document is added to the document library "Business document". Here are list of PowerShell Commands to achieve the functionality.
$web = Get-SPWeb "
http://localhost/mysite/
"
$group = $web.Groups["Notify Members"]
$list = $web.Lists[" Business document"]
foreach ($user in $group.Users){
$alert = $user.Alerts.Add()
$alert.Title = "Alerts"
$alert.AlertType = [Microsoft.SharePoint.SPAlertType]::List
$alert.List = $list
$alert.DeliveryChannels = [Microsoft.SharePoint.SPAlertDeliveryChannels]::Email
$alert.EventType = [Microsoft.SharePoint.SPEventType]::Add
$alert.AlertFrequency = [Microsoft.SharePoint.SPAlertFrequency]::Immediate
$alert.Update()
}
$web.Dispose()
Enabling Alerts in SharePoint 2013 - PowerShell Commands
Up Next
Powershell Commands VS Stsadm Tool in SharePoint 2013
Ebook Download
View all
Getting Started with SharePoint Framework Development using TypeScript, PnP JS, and React JS
Read by 4.9k people
Download Now!
Learn
View all
Membership not found