I am building a script that catches emails. I have access to the email
source and I would like to distinguish between bounced emails, auto-replies
and real replies. Is there a standard that all servers follow for rejected
emails. I am looking for a unique string I can search for like "Mail
Administrator" or "Failed email." Does anyone know or know where I can
look?
We're using the subroutine below to send emails via our classic ASP apps. However, we'd like to know if an email address isn't good -- in other words, it bounced back. Is there a way to do that with the CDOSYS email method? The From email is just some generic text and not a real email address in our apps.
One brute force technique is to hit the Active Directory and see if the email's on it. Is there any other way? Does the CDOSYS method throw any errors that can be trapped? It sends emails to bad email addresses just as quietly as to good ones....
At the bottom of every page I have that makes a Connection and (maybe) creates a Recordset object I have the following code just in case there is an error anywhere: Code:
guide me towards a script that can handle bounced emails from a newsletter campaign. I am not interested in .Net solution. The mail server is Exchange 2003 if that helps. Right now clueless about tracking of bounced emails.
how do you effectivly catch errors in your ASP scripts? For instance, in my current project, I want the administrator to specify details about his database and then have the script test the connection. If something goes wrong I want to report it to the user in a nice orderly fashion instead of using the white screen IIS error.
Now, the way I was thinking I would use "On Error Resume Next" so that the error is skipped over, and then I can use the Server.GetLastError to return an Error Object. However, I see a problem in that the last error might not be the error for the database connection.
I thought to myself, "self, we're going to have to grab the last error BEFORE the database connection, then grab the last error AFTER the database connection and see if they match." But I see a problem in that logic because if I use included files with functions for certain tasks (such as running an SQL statement against a datasource) any instance of the same db error will generate the exact same Error object from Server.GetLastError. How can I be sure that my error is coming from where I want it to come from?
I'm currently doing this membership module and Have a section where the user is prompted for their Date of Birth, So I decided that the best way to display this is with 3 drop down menus for dd/mm/yy. The information is sent into the DB in this date format as well.
dd has the numbers 1-31 mm has 1 -12 and so on...
Well, here is my problem. Say the user fools around and enter 31-2-1990 and cause february can never have 31 days my response page gives me "Providererror '80020005' Type mismatch."
I want to put an error catching feature for this where maybe catch this '80020005' in my response page and redrect them back to the form.....
Im running a simple mail system program which emails newsletters to a database list of 3000+ users.
The program loops through a database containing the emails and sends them out using ASPEmail.
My question is, is there some way i can validate each email address so that if there are invalid characters e.g. the space in "blah @blah.com" it will skip the record and continue the loop.
At the moment i have a working program however, whenever the program comes across an invalid email address it stops at that record and prevents the program from emailing any further.
I am having a problem formatting an email message which comes from a form.
I am currently having difficulty with the <br> tag which I am using for line spaces within my email. I am getting an expected statement error message which is pointing to the line which is underlined below. I can't think what is causing this.
1. I want users to type in their email address on a textfield, and after users press the "Submit" button. The info will automatically go to another person's email to receive a compliment, suggestion, etcetera.
2. Another is how to include the message written on a textarea of a form with the ASP code supplied below: Code:
how to write to check verification valid email thru nslookup or mx record or dns record. Is it possible to do that. Is there any tutorial from sitepoint, previously found it but i lost the link.
example to check assume test@domain.com is not a real email, abc@domain.com is real email how do u check it.
Just starting to play with scripts, and need a little guidance. I want to check to make sure that the email addresses users enter in a form are identical before it will allow them to submit. here's what i have:
the variable for the second email address is EmailFrom2
'validation Dim validationOK validationOK=true If (Trim(EmailFrom)="") Then validationOK=false If (validationOK=false) Then Response.Redirect("emailerror.htm?" & EmailFrom) If (Trim(Name)="") Then validationOK=false If (validationOK=false) Then Response.Redirect("nameerror.htm?") If (Trim(CityState)="") Then validationOK=false If (validationOK=false) Then Response.Redirect("citystateerror.htm?") If (Trim(SchoolName)="") Then validationOK=false If (validationOK=false) Then Response.Redirect("schoolnameerror.htm?")
Set myMail=server.CreateObject("CDO.Message") myMail.Subject="subject" myMail.From="me" myMail.To=request.form("email") myMail.TextBody="hello" myMail.Send set myMail=nothing
this script sends emails to some addresses but not others--and its based on the email service it's sending to. for instance, hotmail email addresses get the email, but mail.com email addresses dont get the email. i have tried sending it to other email hosts, too, and still, some work, some don't. what is going on here?
Dim Mail Set Mail = Server.CreateObject("CDONTS.Newmail") mail.From = "abc@hotmail.com" mail.to = "xyz@hotmail.com" mail.subject = "Test Email Subject" mail.body = "This is Email body message" mail.send
Now the question is that this code will use the Default Virtual SMTP Server in IIS, but I want to use my ISP's SMTP server. please tell me how to do this. I have used my ISP's email server in Outlook express and it is working fine. Please do not suggest to use "CDO" or "CDOSYS" to use for sending emails because I must have to use "CDONTS".
has anyone got a function or subroutine which will remove blank out or remove email addresses.
i've wrote a function which will remove valid email addresses, it's pseudo addresses such as "blah @ blah.com" or "blah_at_blah_dot_com" or "blah_at_blah_._com"
the function is basically to stop users posting an email address in a message.
I've created an com+ application for sending emails with multiple attachments.The component looks like this:
Public Function SendMail3(toAddr, whoAddr, docSubj, docMsg, ByVal docType As Integer, Optional cc = "", Optional bcc = "", Optional sFolder = "", Optional user = "") On Error GoTo MailErr Set oFlds = oConf.Fields oFlds(cdoSendUsingMethod) = cdoSendUsingPort oFlds(cdoSMTPServer) = SMTPSrvr oFlds(cdoSMTPServerPort) = SMTPPrt oFlds(cdoSMTPAuthenticate) = cdoBasic oFlds.Update Set oMail = New CDO.Message oMail.From = whoAddr oMail.To = toAddr If (cc <> "") Then oMail.cc = cc If (bcc <> "") Then oMail.bcc = bcc If oFSO.FolderExists(sFolder) Then Set oFolder = oFSO.GetFolder(sFolder) For Each oFile In oFolder.Files If InStr(oFile.Name, "_" & user) > 0 Then oMail.AddAttachment oFile.Path FileSize = Format((FileLen(oFile) / 1024) / 1024) SumSize = SumSize + FileSize oFSO.DeleteFile (oFile) End If Next End If End If End If If ((docType Mod 2) = 0) Then oMail.TextBody = docMsg Else: oMail.HTMLBody = docMsg End If If (SumSize > 10) Then ErrorStrMail = "Attachment size too large!" GoTo MailFlee End If oMail.Subject = docSubj Set oMail.Configuration = oConf oMail.Send MailFlee: Exit Function MailErr: ErrorStrMail = Err.Number & ":" & Err.Description Resume MailFlee End Function
When I call this component from an asp page,I don't get any error,but the mail doesn't work.....did I do something wrong?
I have set up an interactive database with a .asp page requesting information to include an email address. After receiving a response and viewing the database no email address is entered. How do I set up my table to except an email address?
Is there anyway to send email with ASP without downloading a bunch of stuff? I am new to ASP and I am using IIS on my computer and I can find anyway to send emails from my site.
I need to be able to email to all email addresses in db (like a newsletter) I have seen some code samples but really need something simple and web based.
I am sending email using CDO..the code I am using sends an ASP page, the HTMLpart is recognised,but<%code %> is not(basically I am passing some query strings to ASP page),
SUB SENDEMAIL(refno1) Dim myMail dim mailmessage Set myMail=CreateObject("CDO.Message") myMail.Subject="Sending email with CDO" myMail.From="mymail@mydomain.com" myMail.To="ravi@v.com" myMail.CreateMHTMLBody "http://localhost/mailer/thank_you.asp" myMail.Send
I'm a php guy being forced to work with asp. I have a csv file that is going to have 100 names e-mail addresses. I need to create a script that will read thru the file and then send out one e-mail per name. I've had success adapting brainjar's scriipt for my needs in the past but am not sure on how to read a csv file to get the names and addresses.
I'm looking for some advice on reading a csv file to load the values into an array and then how to handle looping thru it 100 times.
This is what I'm using to process it: <% my_from=request("mail-fromName") my_fromAddress=request("mail-fromaddress") my_to=request("mail-toName") my_toAddress=request("mail-toaddress") my_subject=request("mail-subject") my_relay=request("mail-relay")
I want to be able to redirect and I don't know if this is the best way to do it or not. I also want to include it in my project but when I try to place it inside my project it gives me an error that there can only be one declarative. Please help as I am new to ASP
I'm using the following codes to send the HTML form as an email. While submitting the form i'm not getting any error message. But i'm not getting the email also.
i have a requirement of sending an email thru ASP, I am using Interdev to develop the asp page to send the mail, i am using windows XP & IIS 5.0 version. i am using CDONTS, i downloaded the dll and have registered it in registry, my problem is, code seems to be working and email is not being sent, i have tried out serveral things which were listed in websites but nothing i got right. all the mails are being stored in queue folder in Inetpub/mailroot folder. i doubt whether the norton antivirus which i have installed is blocking or any settings i have missed out in SMTP properties or in IIS settings.
I have IIS 5.1 installed on my cpu with the SMTP service. Am I able to create an object to send email with that, or do I need some third party program installed. Anyone have a sample script?
I am trying to send an email.The email which gets sent to the person right now consists of the contents which he filled out before hitting submit for ex: name,date,phone,emailaddress...
Apart from this information to be sent ,i want to send normal information to the sender in the same email which says something like this: Code: