Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
emailing recipients from a list in Excel
I have the code to e-mail a spreadsheet and/or a reference
of cells to multiple recipients if I list the recipients in the code. (recipients = array:("user1", "user2")) Is there a way to have the code reference the spreadsheet for the list of names instead of having them hard coded? Also, Is there a way to turn off the security prompt that either Outlook or Excel displays when sending an email? (You are about to send an e-mail, are you sure you want to do this?) Thanks in advance!! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
emailing recipients from a list in Excel
Hi Jeff,
The following macro will put all the contents of Column A in an Array called Recipients: Sub StoreRecipients() Dim i As Integer Dim Recipients() As Variant i = 1 Do Until Cells(i, 1) = "" ReDim Recipients(i) Recipients(i) = Cells(i, 1) i = i + 1 Loop End Sub ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
emailing recipients from a list in Excel
Jeff
I have the code to e-mail a spreadsheet and/or a reference of cells to multiple recipients if I list the recipients in the code. (recipients = array:("user1", "user2")) Is there a way to have the code reference the spreadsheet for the list of names instead of having them hard coded? Dim olMi as MailItem Dim cell as Range For Each cell in Range("A1:A10") olMi.Recipients.Add cell.Value Next cell Also, Is there a way to turn off the security prompt that either Outlook or Excel displays when sending an email? (You are about to send an e-mail, are you sure you want to do this?) See here http://www.rondebruin.nl/sendmail.htm#Prevent There is no good way, in my opinion, but at least you'll know. -- Dick Kusleika MVP - Excel www.dicks-clicks.com Post all replies to the newsgroup. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Creating emailing list from column of addresses | Excel Discussion (Misc queries) | |||
Sending Excel sheet to 42 recipients doesn't work. Why? | Excel Discussion (Misc queries) | |||
setting up a mailing list for bulk emailing with handimail | Excel Discussion (Misc queries) | |||
when emailing xp excel documents recipients are unable to open | Excel Discussion (Misc queries) | |||
How do I email selected excel cells to multiple recipients? | Excel Worksheet Functions |