How to configure SharePoint Outgoing Email Settings Using PowerShell
0 Comments
Here is a little script that lets you configure SharePoint Outgoing Email Settings using Power Shell. #Vlad Catrinescu www.vladcatrinescu.com$SMTPServer = “192.168.1.20”$EmailAddress = “svcfarm@vlad.loc”$ReplyToEmail = “svcfarm@vlad.loc”Try{ Write-Host -ForegroundColor White ” – Configuring Outgoing Email…” $loadasm = [System.Reflection.Assembly]::LoadWithPartialName(“Microsoft.SharePoint”) $SPGlobalAdmin = New-Object Microsoft.SharePoint.Administration.SPGlobalAdmin $SPGlobalAdmin.UpdateMailSettings($SMTPServer, $EmailAddress, $ReplyToEmail, 65001)}Catch{ Write-Host “Failed”} Say Thanks if it helped 🙂