Vincent
Posts: 31
|
Posted: 03/31/2008, 10:31 AM |
|
I will use the "AfterUpdate" event for that. You can either use the send mail action or use some custom code as shown below as an example.
If ExecuteFlag And (Not ErrorFlag) Then
Dim userEmail, assignedUserEmail, Sujet, Commentaires As String
userEmail = FormNameFieldName.text
assignedUserEmail = "contactus@somewhere.com"
Sujet = FormNameFieldSubject.text
Commentaires = FormNameFieldComments.text
Dim newMessage As New System.Web.Mail.MailMessage()
newMessage.From = userEmail
newMessage.To = assignedUserEmail
newMessage.Bcc = "someoneelse@somewhere.com"
newMessage.Subject = Sujet
newMessage.BodyFormat = System.Web.Mail.MailFormat.Html
newMessage.Body = Commentaires
System.Web.Mail.SmtpMail.SmtpServer = "your.mail.server"
System.Web.Mail.SmtpMail.Send(newMessage)
End If
Hope this helps.
Vincent
|