put all email address in outlook from a continues form

  • Thread starter Thread starter Song Su
  • Start date Start date
S

Song Su

Office 2007


I have a continues form with 'email' field. I want to design a button so
when clicked, all valid emails (length > 8) will be put in To field of
outlook.

Any help is appreciated.
 
Got it! Nice.

You are a great help!

ErezM via AccessMonster.com said:
hi
to loop throgh all records on a form use:
dim strAdrs

with me.recordset
.movefirst
while not .eof
strAdrs=strAdrs & !eMail & ";"
.MoveNext
Wend
End With

to get rid of the last ";" use
strAdrs=left(strAdrs,Len(strAdrs)-1)

now you have all addresses chained in strAdrs. you can send an email using

DoCmd.SendObject and put the strAdrs in the "To" section

good luck
Erez
 
Back
Top