Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ASP mail with cdonts through an Exchange server

Status
Not open for further replies.

borsk

IS-IT--Management
Dec 3, 2001
8
0
0
US
Hi, im going desperate here.

I want on our Intranet be able to have a form to fill out and sent it, using cdonts and the exchange server.

I have tried alot of things and i cant get the SMTP server configured right, actully i dont know how i just tried alot of bull, the mails i create just keep popup in the queue folder with an error messeage.

I need help to configure the SMTP server and maybe how to update the Cdonts to work with exchange

my system: NT4.0 with IIS 4.0 and a NT4.0 with Exchange 5.5 SP3

hope you can help thansk

Jesper
 
When I ran into this problem a while back it was a security issue with our exchange server not having rights to the folder --- Microsoft actually had some good help -

Remember these variables
strFrom = Trim(Request.Form("txtFrom"))
strTo = Trim(Request.Form("txtTo"))
strCc = Trim(Request.Form("txtCc"))
strBcc = Trim(Request.Form("txtBcc"))
strReplyTo = Trim(Request.Form("txtReplyTo"))
strSubject = Trim(Request.Form("txtSubject"))
strBody = Trim(Request.Form("txtMessage"))
lngImportance = Trim(Request("optImportance"))
lngMsgFormat = Trim(Request("optMsgType"))
lngMsgEncode = Trim(Request("optMsgEncode"))
lngAttEncode = Trim(Request("optAttEncode"))
strFileName = Trim(Request.Form("txtattfile"))

Set objMsg = Server.CreateObject("CDONTS.NewMail")
If Len(Trim(strReplyTo)) > 0 Then
objMsg.Value("Reply-To")=strReplyTo
End If

objMsg.From = strFrom
objMsg.To = strTo
objMsg.Cc = strCc
ObjMsg.Bcc = strBcc
objMsg.Subject = strSubject
objMsg.Importance = lngImportance
objMsg.BodyFormat = lngMsgFormat
objMsg.MailFormat = lngMsgEncode
objMsg.Body = strBody
If Len(Trim(strFileName)) > 0 Then
objMsg.AttachFile strFileName, , lngAttEncode
End If

objMsg.Send
Set objMsg = Nothing

WriteHTML("The following message was sent via
CDO for NTS:")
WriteHTML("From: " &strFrom)
WriteHTML("To: " &strTo)
WriteHTML("Cc: " &strCc)
WriteHTML("Bcc: " &strBcc)
WriteHTML("Reply To: " &strReplyTo)
WriteHTML("Subject: " &strSubject)
WriteHTML("Body: " &strBody)
WriteHTML("Importance: " &lngImportance)
WriteHTML("Message Format: " &lngMsgFormat)
WriteHTML("Message Encode: " &lngMsgEncode)
WriteHTML("File Attachment: " &strFileName)
WriteHTML("File Attachment Encode: " &lngAttEncode)

and look here one MS's site -


Hope it helps
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top