Erratic email performance

Results 1 to 2 of 2

Thread: Erratic email performance

  1. #1
    Join Date
    Dec 1969

    Default Erratic email performance

    I have a page which processes ecards. Users fill in a form, and the data gets loaded into a db, and recipients get emailed to say they&#039;ve got the ecard. <BR><BR>However in about 25% of cases, the user does not get the ecard.<BR><BR>My host uses ServerObject&#039;s ASPMail. The script that sends the email out is at the start of the process.asp page before the &#060;HEAD&#062; tag, and this is what it looks like:<BR><BR>BODY = "Test line"<BR>Set Mailer = Server.CreateObject("SMTPsvg.Mailer")<BR>Mailer.Fr omName = from_name<BR>Mailer.FromAddress= from_email<BR>Mailer.RemoteHost = ""<BR>Mailer.AddRecipient to_name, to_email<BR>Mailer.Subject = "ecard sent..."<BR>Mailer.BodyText = body<BR><BR> if Mailer.SendMail then<BR> Response.Write "&nbsp"<BR> else <BR> err = "INSERT INTO j_ecard_err (fldDate, errorDesc, cardID) VALUES (now(), &#039;"&Mailer.Response&"&#039;,"&maxID&")"<BR> set errRS = oConn.Execute(err)<BR> &#039;Response.Write "Mail send failure. Error was " & Mailer.Response<BR> end if<BR><BR>Set Mailer = nothing<BR><BR>There are no loops or reponse.redirects above the code, which would mean that at some point the page might redirect to another page, it should just run from top to bottom without a problem. I have tried for a while to BCC the email to myself, but they don&#039;t come through all the time either, so something is going wrong.<BR><BR>e.g. Today 20 ecards were sent from the site, but I only got 15 BCC emails. So I presume if I didn&#039;t get the email neither did the person the ecard was destined for.<BR><BR>I&#039;ve set the code to write the code to a db if it doesn&#039;t work, but for some reason this db is still empty, so even though the email code isn&#039;t executed, it&#039;s not I presume because it&#039;s erroring, otherwise it&#039;d be added to the database.<BR><BR>The rest of the ASP code to enter the data into the database does not error out either. I&#039;ve tested the page myself a number of times and it runs fine. I don&#039;t use &#039;on error resume next&#039; or any error trapping on any other part of the page, so if it was going to error I&#039;d get an error message. Instead it seems to run fine, but sometimes the email does not get sent.<BR><BR>And ideas?<BR><BR>Thanks<BR><BR>Jim

  2. #2
    Join Date
    Dec 1969

    Default RE: Erratic email performance

    Jim:<BR><BR>ASPmail is really antsy about the AddRecipient, and won&#039;t send if it&#039;s not complete with a &#039;Name&#039; and email address. Is it possible some folks are leaving off the name? Still, it should still throw an error if that were the case.<BR><BR>Have you tried logging the smtp errors? Works pretty well. The exact code for it can be found at the ServerObjects site.<BR><BR>And the last thing is, you may want to contact your host and see what they have to say. I know if ASPmail is queued they can peek into the queue and see what they have going out - but for &#039;one-offs&#039; they are limited in what they can tell you.<BR><BR>Hmmm - that may be something worth trying. Maybe set your ASPmail to Queue - if they support the ASPQmail component - and then the host can check the queue directoty.<BR><BR>Hope any of this has helped.<BR><BR>KurtW

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts