Catching an error from CDONTS New Mail
I need to find away to catch an error if CDONTS” New Mail dose not deliver the email. I have searched for manuals on this but have only found short references on how to send email, nun of them say anything a bought returning an error
IS the code for sending email using cdonts different if you are running a windows 2000 server with exchange 2000 as opposed to running a different windows server (NT) with exchange 5.5?
if I upgrade the server to exchange 2000 from 5.5 do i have to reinstall the cdo.dll on the server??? do i need to somehow reinitialize the cdo so it's active?
I had a webmail CDONTS script working.quite well too I think I had an error saying mail.to had a type mismatch. I went through the database (it's a web form mailing list for a client) and found what I thought to be bad email addresses. Tried it again and it works fine. My question, is there anyway to validate the email address? I am assuming that CDONTS wants the text string to be in a certain format. How can I test the data for a valid format, and then throw out that email address if it is not in the expected format?
I have copied this from another page that I have. The original page takes the details from a form on another page, so the results above are all request.form("whatever") etc, and the original works!!
but if I try to put fixed values in as above it fails to work and I can't see why?
I've even tried a response.write to check the values..and they look right, but no mail is sent
I'm running win XP pro but have taken the CDONTS.DLL from my win 2000 pc and done the regsv32 etc etc
maybe I should try to use CDOSYS but
a) I haven't a clue how and so b) I copied a script directly from a help page which didn;'t work either! c) the eventual host server is running NT4
Sending mails using CDONTS works great but I have (for now) just 1 minor problem. I would like to place the username (of the person located in my database) inside my input-box (type="text") and send that as a page to the person using cdonts.
here's a part of my code (simplified):
HTML = HTML & "<html>" HTML = HTML & "<head>" HTML = HTML & "</head>" HTML = HTML & "<body>" HTML = HTML & Email: <input type=""text"" name=""email"" value=""<% = strEmail %>""> HTML = HTML & "</form>" HTML = HTML & "</body>" MyCDO.Body = HTML
So the problem arises at line 5 here. He does not understand the asp-tags inside the text. Anyone who knows how to solve this?
I had to write a page in ASP which sends an email. I googled and was able to write the following code:
<html> <body> <% Set Mail = Server.CreateObject("CDONTS.NewMail") Mail.To = "XXXXXXXXXXXX@XXXXXX.COM" Mail.From = "YYYYYYYYY@YYYYY.COM" Mail.Subject = "Test MAIL Subject" Mail.Body = " Body Body Body Body Body Bodyody Body Body" If Mail.Send Then Response.Write("Mail has been sent successfully") Else Response.Write("Mail Sending Failed") End If Set Mail = nothing %> </body> </html>
When I run this script on a shared hosting server, It's saying "Mail Sending Failed". I had never written ASP code before and couldn't find what the reason is.. I also checked whether CDONTS.NewMail component is available.
Am looking for help in converting a CDONTS mail form script, which is not supported by my new host, into jscript. I have no fromal training in programming etc... Have self taught myself enough to probably get myself in trouble The following script i had written about 6 years ago for automated webimport intomy CRM "Goldmine" for populating database fields. Anyway, here is my old, and now worthless script...
My problem is, when I send e-mail to our members, not all of them are getting them and there is no rhyme or reason. I was thinking of re-writting the program to go through MS Outlook so our Exchange Server will take care of sending it. Then again, probably there is someone who can help me figure out why some e-mail are not getting delivered even though they have valid e-mail addresses. There must just be about 25-35 out of probably close to 2000 members in our mailing list. I am using SMTP do you think it is getting overloaded with delivery? Sometimes they would come back with a delivery delayed notification.
I posted my code because there might be something in my program that does not work for mass e-mail sending and somebody might want to give me a suggestion on handling this matter.
What if I send the e-mail one by one instead of doing a bcc?
I just found out that CDONTS was indeed installed on our web server so I've been playing around with some easy sample codes. However, when I run the code, nothing happens. I get no errors, it seems like everything went OK, but no email! Are there firewall issues with CDONTS? If so, how can I work around them?
When the person (Mail.To) get's the message, the header only shows the objRS value, followed by a semicolon, the bill.clinton address doesn't show up, although he does get the email.
So, if the 'to' was for Sally Brown, when she get's the email, she only see's one name on the CC line, in this case tom.petersen, she doesn't know it went to bill.clinton as well, unless of course she does a reply to all, then his name will show in the CC part.
Again, the code works, but I am trying ot get it to display right and was wondering if it's the code, as it usually is in my case!
After I run my cdon't.asp file, I saw a successful message saying "mail sent". Then, I went to open my inbox but find no mail. So, I went back to c:inetpubmailroot, I saw a folder called queue and saw that mail there. How do I solve this problem?
When I sent the below statement in body of the CDONTs mail object it replaced the hyphens with question marks.Actual sent message: "Thursday, June 10, 1 - 3 pm" Actual recieved message: "Thursday, June 10, 1 ? 3 pm"
I am working with CDONTS mail object. The code doesn't give any syntax error; but, actually it doesn't work because I don't know how to give my local sever's machine name in the Mail Object's .From property. :P What is the machine name? Could any one give me the right format? Where do I know the machine name from? I tired by right clicking "My Computer" and seeing it's properties. But, I think that's not the machine name.
Let me first outline the environment. The ASP app is running on a Windows 2000 Server within a large controlled network. I know Exchange Server is not required on this server for messages to be forwarded but I have to believe that the Exchage Server on the domain is the only way messages are passed once they leave the Web server.
If the domain's Exchange Server goes down what will happen to messages generated by the ASP app using CDONTS? Will the Web server's SMTP server continue to attempt delivery or do they just get dumped into the bad mail folder?
I am trying to send e-mails to customers in a database. Each e-mail is customised for each customer, so I cannot simply copy all customers on the same e-mail. My logic loops through the appropriate recordset and attempts to send a notification e-mail to each customer. The problem is that about 10 - 20% of the e-mails do not get sent! (I know this because I :bcc myself on all the e-mails.) I also know that there is no problem with the e-mail addresses because when I try again to run the program with the same addresses but a smaller list of customers, those mails go out just fine.
The program generates a report which shows that it tried to send all the appropriate e-mails, but in reality several of the mails were not sent. What's interesting is that all of the e-mails near the beginning of the program execution get sent. But as the program goes on, more and more get skipped. It seems that CDONTS cannot keep up with the program execution.
Does anyone know of a way to solve this? What would be great would be a DO... WHILE loop that kept trying until the e-mail was sent successfully. But, for that approach to work, there would have to be some way for the program to check if the e-mail had gone out successfully. Another option would be a loop that waited until the *previous* e-mail had been sent successfully before attempting to send the next one.
Does anyone know of a way to test either of those conditions or of an alternate approach to avoid this problem I am having?
'Update configuration objConfig.Fields.Update Set objMail.Configuration = objConfig
objMail.From ="info@justonedomain.com" objMail.To = "kmuel@aol.net" objMail.Subject ="Information" objMail.TextBody="This is a test for CDO.message" objMail.Send
If Err.Number = 0 Then Response.Write("Mail sent!") Else Response.Write("Error sending mail. Code: " & Err.Number) Err.Clear End If Set objMail=Nothing Set objConfig=Nothing %>
Can anyone point out why this is not working? It should work.
I'm sending an email in ASP using CDONTS and I'm trying to attach a file from the user's machine (i.e. client side) and right now it works... BUT what im doing now is having the user upload the file and it is saved on the server in the temp directory, then once the email is sent, the file is deleted.
So here's the question... Is there a way to attach a file using only the file info and data - i.e. without saving the file to the server. I have a pure asp upload include file that will let me view a file's data in binray format and I was wondering how I could use this to attach the file.
So to reiterate, can I attach a file that is not saved on the server... any takers?
i am devloping a carrer page. i want 2 give the facility 2 user to upload the resume and send to the mail id. for example in yahoo mail. one can attach resume and send to the desired id. i want to do it in cdonts. so can anybody help me?????
i have create a web pages which is a register form for customer, and then when the customer fill up the form and click submit, it will send a mail to the customer for comfirmation. below is the coding i use: Code:
I run a web site that uses various forms to send email to customers. For example, I have a "Forgot your password?" script and a "Email this page" script.I've found out that when a user sends an email via my site to a Hotmail address, the email just "disappears." I'm assuming Hotmail is considering the email SPAM because it was send by my web server? The site uses ASP and I've tried using CDONTS and CDOSYS (which I specified a SMTP server for) and nothing seems to work for Hotmail.
A large portion of my customers user Hotmail, so banning it really isn't an option.Is there anything I can do to prevent Hotmail from blocking my site's emails?
i have a password reminder page that works, but i'm trying to strip down the username. it's in the database as domain/username, but i don't want the user to see the domain in the email they receive.
when i run the page i get a type mismatch error pointing to the line where i'm outputting the username in the email. i can get this to work when i'm outputting the data to a web page. is it because of cdonts? how would i strip off the data? Code:
I use the following code to send email from an ASP page:
<% Dim objSendMail Set objSendMail = Server.CreateObject("CDONTS.NewMail")
objSendMail.From = "abc@abc.com" objSendMail.To = "abc@abc.com" objSendMail.Subject = "Form Results - Get a Quote" objSendMail.Body = "This is the Body text of this test mail." objSendMail.Send Set objSendMail = Nothing %>
Of course, the the email addresses above are real on my ASP page.
After the above code is executed, I don't receive any email.
Anyone got much of a clue how best to send emails to selected people from a database table and to be able to track them, maybe as much as a read receipt, or perhaps just checking that they don't bounce, or end up in the bad mail folder.
Is this best/possible to try and code or is there a free/cheap component that does this simply.
I have created an asp form which I want to use to retrieve attachment from my site users. I am using Aspupload Component on sever to upload attach file on server at specific location. Although I am able to upload attach file on server. Also I created to retrieve attachment from mail its not working.
Can any one help me out to make form or code to retrieve uploaded file as attachment through mail.
Here is file where user fill his information and attach his CV....
I need some help: with cdosys i'm able to send e-mail from asp using the local exchange server. Now I also have to save the sent mail into the user's mailbox for future reference: how to?
I'm using CDO to send mail to the site owner from ASP pages with forms. Recently one of my forms is occasionally sending email with what seems to be an insertion which is replacing the plain text part of the email with something else. Looking at the server sent email source, the hacked emails have the following:
Here's the scenario. I'm currently using cdosys/asp to send mail to our SMTP server. We use a product called MailFilter to check for SPAM. It doesn't work very well. If MailFilter isn't working cdosys also has problems and emails don't get sent. As these email are confirmations for customer's bookings this means lots of customers calling to see where their confirmation emails have gone. The root of the problem is MailFilter but that here to stay. So I had this thought of sending the message to a queue of some sort so at least they will get to the customer eventually rather than being lost for good. So here's the question:
Can I/How do I send messages to a mailbox on our exchange server using cdo.message?
I'm using CDO from my vb component to fire email. The problem is whenever one of the email addresses in to, or cc is wrong then none of the mails are fired even to the correct addresses. It gives an error like
The server rejected one or more recipient addresses. The server response was: 550 Relaying denied for <xfd@wre.com>
My code goes like this. Why is the mail server trying to look for the validation of email ids??I want that atleast the mail should be fired to the correct email addresses rather than no email fire. Can i achieve that.
Dim iMsg As New CDO.Message Dim iConf As New CDO.Configuration
Set iMsg.Configuration = iConf With iMsg .To = strToEmail .From = strFromEmail .CC = strCCEmail .BCC = strBCCEmail .Subject = strMailSubject If strMailFormat = "TEXT" Then .TextBody = strMailBody Else .HTMLBody = strMailBody End If If strAttachment <> "" Then .AddAttachment strAttachment End If If intPriority = 2 Then .Fields.Item("urn:schemas:mailheader:X-Priority") = cdoHigh .Fields.Update End If
I would like to know if this can be achieved! On the form I a drop down menu that's called ("Escalation_type") the values are eta, hdtv, and supervisors. I have some ideas but I am not sure if it will work or not. If the use chooses an eta as a value I would like it to be sent a mailbox for exam: no@where.com. If they choose hdtv as value I would like it to be sent to a different mailbox. Can this be achieve by using the case statement or the if statement?
I'm looking for an asp code who can send an email without using a mail component. I started to write somethings using winsock but I don't have enough time to finish it.