Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

ASP.NET Forum


You are currently viewing our ASP.NET Forum as a guest. Please register to participate.
Login



Reply
email from a drop down list....
Old 09-09-2004, 07:22 AM email from a drop down list....
Experienced Talker

Posts: 37
Trades: 0
Ive got an asp page setup where people send cause for concerns to relevant people.



However as well as the designated email addresses been used i also want relevant heads of department

to receive the request dependent upon the department the staff member sending the request comes from.



Ive got a htm page with a form on and a drop down list with depts to choose (Art, Business Studies etc)



How do i code it so that when the person filling out the form selects Art for example it sends an email to the

head of art, o r Business Studies to the head of business studies etc???? Ive used this code in the confirmation

asp page:



Code:
 

<%

Dim myCDONTSMail

Dim strFrom

Dim strTo

Dim strSubject

Dim strBody

strFrom=Request.Form("MyEmail")

strTo="me@wickersley.net, them@wickersley.net,"

strSubject = "Cause for Concern"

 

strBody="The following information was submitted regarding an Cause for Concern:" & Chr(13)

strBody = strBody & Chr(13) & "Student Name: "

strBody= strBody & Request.Form("studentname") & Chr(13)

strBody = strBody & "Teacher Name: "

strBody= strBody & Request.Form("teachername") & Chr(13)

strBody = strBody & "Teacher Email: "

strBody= strBody & Request.Form("MyEmail") & Chr(13)

strBody = strBody & "Teachers Department: "

strBody= strBody & Request.Form("department") & Chr(13)

strBody = strBody & "Date of Incident: "

strBody= strBody & Request.Form("MyDate") & Chr(13)

strBody = strBody & "Time of Incident: "

strBody= strBody & Request.Form("time") & Chr(13)

strBody = strBody & "Details of Incident: "

strBody= strBody & Request.Form("incidentdetails") & Chr(13)

strBody = strBody & "Did the incident involve ICT?: "

strBody= strBody & Request.Form("ICT") & Chr(13)

Set myCDONTSMail = CreateObject("CDONTS.NewMail")

myCDONTSMail.Send strFrom,strTo,strSubject,strBody

Set myCDONTSMail = Nothing

 

%>




Hope this makes sense - any help appreciated!



Woody
woody22 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 09-09-2004, 04:45 PM
Alex91's Avatar
Skilled Talker

Posts: 51
Location: Canada
Trades: 0
Well i know what your talking about... Im thinking you might be able to do it like this:
Search google or A Downloads site for something like a form Chain... Come to think of it... heres one:

http://www.dynamicdrive.com/dynamici...ects/index.htm

Customize so Above it have:

Choose an Area

Or whatever than when they click the first dropdown box have Art, Business etc. Than use the Instructions and Script in the zip file to make it After they clicked a certain place make them select who to email or something like head of art, art moderator etc, Than in third box have the email Box.
You can probly take away a box if you only Need 2.


Tell me if this helps... If not search google for How to make a Chained Selct form.
Alex91 is offline
Reply With Quote
View Public Profile Visit Alex91's homepage!
 
Reply     « Reply to email from a drop down list....
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.09269 seconds with 12 queries