Create a powershell script to generate the html file

\nTest-ReplicationHealth | ConvertTo-Html -title "BackupReport CCR" -body "Backup status per Storage Group" | Set-Content E:StorageGroupBackupStatus.html\nnote:\n
test-systemhealth
\n test-servicehealth\n \n\n

Create a powershell script to e-mail log file

\n$filename = “E:StorageGroupBackupStatus.html”\n$smtpServer = “RelayServer”\n$msg = new-object Net.Mail.MailMessage\n$att = new-object Net.Mail.Attachment($filename)\n$smtp = new-object Net.Mail.SmtpClient($smtpServer)\n$msg.From = [email protected]”\n$msg.To.Add([email protected]”)\n$msg.Subject = “CCR Status”\n$msg.Body = “Attached is the CCR status”\n$msg.Attachments.Add($att)\n$smtp.Send($msg)\n

Go into task scheduler

\nFor the program type this\nC:WindowsSystem32WindowsPowerShellv1.0powershell.exe\nFor the arguments use\n-PSConsoleFile "C:Program FilesMicrosoftExchange Serverbinexshell.psc1" -noexit -command ". 'e:SendLogFile.ps1'"