Re: Mail to a group

Tech-Archive recommends: Fix windows errors by optimizing your registry



The exact process will depend on how you're getting the 190 addresses now.

I don't have the code here, but one app I have will parse a list of semicolon delimited
list of email addresses and process them one at a time.

Alternatively, and probably more likely, you have a table from which they reside. Then
it's a simple matter of looping through a recordset.


Dim db As Dao.Database, rs As Dao.Recordset
Dim sSQL As String, sEmail As String, sRecip As String
Dim sBody As String, sSubject As String

sSQL = "SELECT FName & ' ' & LName As Recip, Email FROM tblPersons"
Set db = CurrentDb
Set rs = db.OpenRecordset(sSQL, dbOpenSnapshot)

If Not rs.BOF and Not rs.EOF Then
Do Until rs.EOF
sEmail = Nz(rs!Email, "")
sRecip = Nz(rs!Recip, "")

sBody = "Hi " & sRecip & vbCrLf & vbCrLf & "Here's your email."
sSubject = "Email from The Database System"

' Send email here. You've got the email, a recipient name, body text and subject.
docmd.SendObject , , , to,cc,bcc,subject,messagetext, false


rs.MoveNext
Loop
End If

Set rs = Nothing
Set db = Nothing


The DoCmd.SendObject is something you can read more about in Help files.
--
Danny J. Lesandrini
dlesandrini@xxxxxxxxxxx
www.amazecreations.com


"Leif Thorsen" <LeifThorsen@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote ...
Thank You for Your answer but I don´t think the problem is a mistyped address
because the error message comes long before Outlook has started to send the
e-mails. But - I think Your idea of looping the e-mails as You say but the
problemis that I am not familiar how to do. Can You give me a new hint ?? I
hope You can and therefore THANK YOU IN ADVANCE

Best regards

Leif

"Danny J. Lesandrini" wrote:

Leif:

sometimes error messages are correct and on point. could it be that the
190th email address was mistyped? That would produce the error "unknown
recipients".

I've never heard of a limit on email addresses and if there was, it would
probably be a binary number, like 256 or 128. Maybe it's a question of the
length of the total character string exceeding 8000 characters or something,
but more likely, the error message is correct and you have a bad address.

For that matter, it's probably not a good idea to send out a single email with
190 addresses. Why not loop through and send 1 email 190 times, once to
each recipient? That will make it more likely that the email won't be bounced
by anti-spam software and it will alert you to incorrect email addresses.
--
Danny J. Lesandrini
dlesandrini@xxxxxxxxxxx
www.amazecreations.com


"Leif Thorsen" <LeifThorsen@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote ...
I have in this disscussion forum got a tip of a method to make a group-mail
to a lot of mail-addresses taken from a question. When using this metod it
seems that there is a limitation of how many e-mailaddresses You can use at
the same time. When I have a question with 190 items I will have error number
2295 "Unknown recipients. The letter was´nt sent." When I reduce my items in
the question to below 100 there is no problems. Is there some sort of
limitation for how many e-mailaddresses I can use at the same time ????

Than You in advance for an answer

Leif Thorsen





.



Relevant Pages

  • Re: Mail to a group
    ... recipients without to confirm eaxh mail ??? ... Dim sSQL As String, sEmail As String, sRecip As String ... But - I think Your idea of looping the e-mails as You say but the ... the error message is correct and you have a bad address. ...
    (microsoft.public.access.modulesdaovba)
  • Re: How to convert Infix notation to postfix notation
    ... If this is for an error message, why isn't it using stderr for its output? ... array of 15 characters, and you call this function with the limit 15 on ... Making sure that the only string I allocate and append to, ... because mulFactor in all versions must needs incorporate the functions ...
    (comp.lang.c)
  • Re: Open a form at a specific record
    ... Allen Browne - Microsoft MVP. ... and I get error message Compile error: Expected: end of statement. ... Dim strWhere As String ...
    (microsoft.public.access.queries)
  • Re: Open a form at a specific record
    ... Allen Browne - Microsoft MVP. ... Tips for Access users - http://allenbrowne.com/tips.html ... and I get error message Compile error: Expected: end of statement. ... Dim strWhere As String ...
    (microsoft.public.access.queries)
  • Re: High Value
    ... Verwendung des nordischen Buchstabens Ø in der String() Funktion als Ersatz ... Keine E-Mails auf Postings in NGs senden! ... Online Hilfe von Microsoft Access ...
    (microsoft.public.de.access)