Hi David,
There is a example of this in the samples folder, "Samples -> Scripts -> Windows -> Send error email"
What you is tailor this script, and make one for success and failure. Then using conditions on your tasks, you can link success and failure return codes to this script. The script can be generic, so you can link to the same success email script for all your tasks you want a success email alert for.
Just in case you've deleted your samples folder, here's the Altiris provided script:
'Send mail showing that there was an error.
'vbscript
' Description: This will send an email message to the specified
' recipient using the SMTP server and account to
' indicate an error with the Job that was executed.
'---------------------------------------------------------------------------------------------------
Dim Conf
Dim Message
Dim SMTPServer
Dim FromName
Dim ToName
Dim SendUsername
Dim SendPassword
Const SendUsingPort = 2
' Set the variables used to send the message
SMTPServer = "SMTPSERVER"
FromName = "user@domain.com"
ToName = "user@domain.com"
' Setup the configuration for the message to use
Set Conf = CreateObject("CDO.Configuration")
With Conf.Fields
.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = SendUsingPort
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = SMTPServer
.Update
End With
'Setup the message
Set Message = CreateObject("CDO.Message")
With Message
Set .Configuration = Conf
Dim JobName
JobName = """%CALLINGJOBNAME%"""
'Set email adress, subject And body
.To = ToName
.Subject = "%COMPNAME% " & JobName & " job Failed"
.TextBody = "DS Job " & JobName &" for " & "%COMPNAME%" & " Failed at " & Date & " " & Time
.From = FromName
.Send
End With