Multiple Email recipients and Submission Email reciept

S

Steven

We have multiple forms on our htm site which post to email and to
sharepoint on our SBS 2003 server. When a client fills out a form it is
routed via exchange to the correct office/employee and that's all fine. The
confirmation pages work fine as well but do not suffice. I'm interested in
finding a way to automatically generate an email "reciept" which also goes to
the person who submitted the form with all of the order information included
and formatted with HTML to reflect the visual appearence of the website or
close proximity.
I read Jim Buyens fp inside out and sharepoint book and they get to this
point but do not go further.
Could someone kindly point me to a code sample, explanation or resource
which documents how to do this?
I have VB.Net, C#.net and C++.net and frontpage 2003 for my toolset.
kind Regards,

Steven Whitcomb
 
J

Jim Buyens

Howdy.

I think the best approach would be to stop using the FrontPage "Save Results
As Mail" facility and instead, create an ASP.NET page that sends the mail.
Basically, you:

1. Add a reference to the System.Web.Mail namespace.
2. Create a new MailMessage object.
3. Set its From, To, and Subject properties in the usual way.
4. Set its BodyFormat property to MailFormat.Html.
5. Set its Body property to the HTML for the mail. (You'll have to build
this in code).
6. Set SmtpMail.SmtpServer to the DNS name of your SMTP mail server.
7. To send the mail, call SmtpMail.Send(yourMailMessageObject).

For more info, browse:
http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemwebmail.asp

Jim Buyens
Microsoft MVP
http://www.interlacken.com
Author of:
*-----------------------------­-----------------------
|\----------------------------­-----------------------
|| Microsoft Windows SharePoint Services Inside Out
|| Microsoft Office FrontPage 2003 Inside Out
||----------------------------­-----------------------
|| Web Database Development Step by Step .NET Edition
|| Microsoft FrontPage Version 2002 Inside Out
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/----------------------------­-----------------------
*-----------------------------­-----------------------
 
S

Steven

Howdy Jim,
I was affraid you were gonna say that. How much do you know about using the
old Autoresponder gag with the reply to: field? Another thread goes down that
path, but my only deal is on our servers we use a distribution list email
address to circulate the form to half a dozen staff members. Since the
distribution email is just a shared folder in Exchange and NOT an actual user
in active directory with an actual Email Box and login, I'm not exactly sure
how to log into the email account and set the autoresponder up to begin with.
I'll take a look see at that link you provided and be able to tell if it
will turn my brain into swiss cheese or not.
Thanks for the reply,
Enjoyed your books, they were both done exceptionally well.


Regards,

Steven
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top