Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Email stopped working ("CDONTS.NewMail")

Posted on 2003-03-15
8
Medium Priority
?
414 Views
Last Modified: 2007-12-19

I use the following script in my ASP pages, this code stopped working suddenly. Is anybody can able to able me?
---------------------

set sendMailer = Server.CreateObject("CDONTS.NewMail")
     sendMailer.MailFormat=0
     sendMailer.BodyFormat=0
     sendMailer.From = "Riaz"

     sendMailer.To = trim(objRec6("email"))    
     sendMailer.Subject = "Your adv. at ........."
     sendMailer.body = mess
     sendMailer.Send
     Set sendmailer = nothing          
     Response.Redirect "adm.asp?userval="&user1&","&userlog
end if

-----------------------
I checked with the service provider who asked me to sent the mail server as "supermail._______.net"

Can you tell me, where I will have to insert this "supermail.________.net" in order to make codes workable.  I don't have much experience.

Thanks  
0
Comment
Question by:peergs
8 Comments
 
LVL 10

Accepted Solution

by:
apollois earned 300 total points
ID: 8145656
Hi peergs,

CDONTS assumes that the SMTP server is on the same machine as the web server.  If the web server is running on W2K Server, then CDOSYS is a better choice.  It will allow you set the SMTP server.

Here's a good place to start learning about CDOSYS:

CDOSYS Common Programming Tasks/Creating a Message Object
http://msdn.microsoft.com/library/en-us/cdosys/html/_cdosys_creating_a_message_object.asp 

To set the SMTP server for CDOSYS, see:
Configuring Network Authentication Information
http://msdn.microsoft.com/library/en-us/cdosys/html/_cdosys_configuring_network_authentication_information.asp

Best Regards,
>apollois<
0
 
LVL 10

Expert Comment

by:apollois
ID: 8145721
peergs,

Here is another article that may help:

HOWTO: Send HTML Formatted Mail Using CDO for Windows 2000 and a Remote SMTP Service
http://support.microsoft.com/?id=286431

Best Regards,
>apollois<
0
 
LVL 2

Expert Comment

by:ActiveMedia
ID: 8146229
CDONTS works fine for me!

1. I think the line at fault is:

    sendMailer.From = "Riaz"

Because .From must be followed by a valid (even if fictitious) email address.

    sendMailer.From = "Riaz@Riaz.com"




2. Presumably you are confident that:

   sendMailer.To = trim(objRec6("email"))    

always contains a valid genuine email address. Shouldn't it be validated somewhere?


HTH
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 1

Expert Comment

by:Yawgmoth
ID: 8146808
ActiveMedia CDONTS prbably works well for you because the SMTP server is on the same physical machine as your script.  If this were a 2000 Machine I don't thik you could even create an instance of CDONTS (i could be wrong).  But yeah just to add my own 2 cents appolois is absolutely correct CDONTS os flawed.  
0
 
LVL 7

Expert Comment

by:cstsang
ID: 8150487
do you mean your program works in past?
Can you give us more detail your environment?
Such as your OS,intranet/internet environment.
0
 
LVL 7

Expert Comment

by:cstsang
ID: 8150534
Or
put the "supermail.________.net" in smarthost setting in your SMTP server.

If you want to have more detail step ,please let me more about your environment.
0
 
LVL 7

Expert Comment

by:cstsang
ID: 8150536
Or
put the "supermail.________.net" in smarthost setting in your SMTP server.Then restart your SMTP server.

However,if you want to have more detail step ,please let me more about your environment.
0
 
LVL 58

Expert Comment

by:Gary
ID: 9349742
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Accept Answer by apollois

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
GaryC123
EE Cleanup Volunteer
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses
Course of the Month11 days, 14 hours left to enroll

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question