This is a discussion on "Getting a "At least one recipient is required, but none were found." error message" within the Classic ASP section. This forum, and the thread "Getting a "At least one recipient is required, but none were found." error message are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
Getting a "At least one recipient is required, but none were found." error message
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
|||
|
|||
|
Getting a "At least one recipient is required, but none were found." error message
Hi I'm getting an error message from a forgott user password send mail script and I can't seem to see where I'm going wrong.
The db field for the email address is called user Here is the script: <%Dim Mail Const cdoSendUsingMethod = "http://schemas.microsoft.com/cdo/con...tion/sendusing" Const cdoSendUsingPort = 2 Const cdoSMTPServer = "http://schemas.microsoft.com/cdo/con...ion/smtpserver" Const cdoSMTPServerPort = "http://schemas.microsoft.com/cdo/con...smtpserverport" Const cdoSMTPConnectionTimeout = "http://schemas.microsoft.com/cdo/con...nectiontimeout" Const cdoSMTPAuthenticate = "http://schemas.microsoft.com/cdo/con...tpauthenticate" Const cdoBasic = 1 Const cdoSendUserName = "http://schemas.microsoft.com/cdo/con...n/sendusername" Const cdoSendPassword = "http://schemas.microsoft.com/cdo/con...n/sendpassword" Dim objConfig ' As CDO.Configuration Dim Fields Dim objMessage Dim Body Set objConfig = Server.CreateObject("CDO.Configuration") Set Fields = objConfig.Fields With Fields .Item(cdoSendUsingMethod) = cdoSendUsingPort .Item(cdoSMTPServer) = "mail.mydomain.co.uk" .Item(cdoSMTPServerPort) = 25 .Item(cdoSMTPConnectionTimeout) = 10 .Item(cdoSMTPAuthenticate) = cdoBasic .Item(cdoSendUserName) = "admin@mydomain.co.uk" ' replace with the username .Item(cdoSendPassword) = "milme" ' and password for the smtp server you're using .Update End With Set objMessage = Server.CreateObject("CDO.Message") Set objMessage.Configuration = objConfig %> <%Dim Pears Set Pears = Server.CreateObject("ADODB.Connection") Conn = "DRIVER={Microsoft Access Driver (*.mdb)}; " Conn = Conn & "DBQ=" & Server.MapPath("../../db/mydb.mdb") Pears.Open(Conn) SQLtemp = "SELECT * FROM [password] WHERE [user] = '" & request.querystring("get") & "' " Set rs = Pears.Execute(SQLtemp) If rs.bof And rs.eof Then response.redirect ("forgot2.asp?msg2=no&msg=We+could+not+find+you r+e-mail+address+in+our+database.+Please+join+below.") Else End If %> <% objMessage.To = user ' your recipient objMessage.From = "admin@sedao.co.uk" ' your sender objMessage.Subject = "Thanks for your enquiry" buf = "Dear " & rs("name") & vbCrLf buf = buf & " " & vbCrLf buf = buf & "Thanks for your enquiry." & vbCrLf buf = buf & " " & vbCrLf buf = buf & "Your password is:" & " " & rs("pass") & vbCrLf buf = buf & " " & vbCrLf buf = buf & "Regards" & vbCrLf buf = buf & "The Administrator" & vbCrLf objMessage.HtmlBody = buf%> <% objMessage.Send Set objMessage = Nothing response.redirect ("forgot2.asp?msg2=yes&msg=Your+password+was+send+ to+" & request.querystring("get")) %> Can anyone see where I'm going wrong? thanks in advance. |
|
|
|
#2
|
|||
|
|||
|
Re: Getting a "At least one recipient is required, but none were found." error message
I sorted it I hadn't completed the "Else" statement. Doh
![]() |
![]() |
| Tags |
| getting, quotat, least, recipient, required, but, none, were, foundquot, error, message |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Creating a "tag" system to find relevant "related" pages | MrQuestions | PHP Forum | 3 | Mar 20th, 2008 23:06 |
| [SOLVED] Getting the "Microsoft JET Database Engine error '80040e14'" error. | VegaLA | Classic ASP | 3 | Jan 26th, 2008 00:12 |
| ? IS "meta name="robots" content="?" necessary in pages ? | Love2Java | Starting Out | 6 | Aug 8th, 2007 13:48 |
| Flash "Click Here to Activate" message | lyndaelyzoo | Flash & Multimedia Forum | 3 | Jul 6th, 2007 03:01 |
| window.opener.document["nameForm"].getElementById("someid").value; doesnt work | drpompeii | JavaScript Forum | 0 | Feb 17th, 2007 23:09 |