CDONTS  
Author Message
CDONTS and Email Does not Work





PostPosted: Visual Basic for Applications (VBA), CDONTS Top

I have a question regarding my code in FrontPage.

I am trying to send an email from my HTML form, based upon an asp file that the form reads. It is not working, but here is my code:

<%
Dim myCDONTSMail
Dim strFrom
Dim strTo
Dim strSubject
Dim strBody
"
"
strSubject = "Someone Has Submitted a Helpdesk Request"
strBody="The following information was submitted:" & Chr(13)
strBody = strBody & Request.Form("Entered_By_Fname") & " "
strBody = strBody & Request.Form("Enter_By_Lname")
strBody = strBody & Chr(13) & Request.Form("Date_1") & Chr(13)
strBody = strBody & Request.Form("Title") & Chr(13)
strBody = strBody & Request.Form("Description") & Chr(13)
strBody = strBody & Chr(13) & "Thank you for submitting your data."
Set myCDONTSMail = CreateObject("CDONTS.NewMail")
myCDONTSMail.From = strFrom
myCDONTSMail.To = strTo
myCDONTSMail.Subject = strSubject
myCDONTSMail.BodyFormat = 0 'This indicates HTML
myCDONTSMail.Body = strBody
myCDONTSMail.Send
'myCDONTSMail.Send strFrom,strTo,strSubject,strBody
Set myCDONTSMail = Nothing
%>

Help!



Microsoft ISV Community Center Forums1  
 
 
duck thing





PostPosted: Visual Basic for Applications (VBA), CDONTS Top

Are you getting errors when you try to run it If so, are you able to use the JIT de**** to look at the script



 
 
CDONTS and Email Does not Work





PostPosted: Visual Basic for Applications (VBA), CDONTS Top

No, I am not receiving an error message; that is the most frustrating part because I can't fix what doesn't indicate that it's broken.

I am not too familiar with the JIT de****; so, I haven't had the opportunity to use that tool.

Just as a side note, the first part of my code (which I do not have listed) is taking user input on the HTML form and sending the data to a SQL database. This is working just fine. A confirmation page loads at the end stating, "....you will be receiving an email soon. Thank you for .....blah, blah, blah". Mind you, the email piece is in the asp file as well, again not giving me any error message that anything is wrong.

I know that my SMTP server is setup correctly, to include the correct services running, because I created a feedback form and set the action of the form to send email to me directly, and it worked and still does work just fine.

Here is more information, I am using CDONTS, which doesn't work with Windows XP Pro (which is the OS that I am using for this project), unless you register the CDONTS.dll from another OS, like Windows 2000 or something, which is what I did. CDONTS is said to not work with XP Pro, but again the .dll is registered and in the system32 folder. I can use CDOSYS, which works with XP Pro, but would really like to get my current code working.

Any ideas Thank you soooooooo much!!!