You are on page 1of 10

Hi Excel user

You can test a few examples in this workbook to send a workbook/sheet(s)/selection/range in a new workbook if you have a account in Outlook Express, Windows Mail, Windows Live Mail or Outlook. Tip: See the Outlook object model code on my site if you use Outlook, you have much more options then. The Examples are working in Office 2000 - 2010 and some in 97-2010 The examples on the first three worksheets on this page display the mail so you can use the addressbook to use the address you want or enter text in the body of the mail. See the code on my site if you know the address and want to send the mail directly. Note: on the webpage for each example there is more information ( there is a link on each worksheet) Read also the tip page for the SendMail examples http://www.rondebruin.nl/mail/tips1.htm

See my site for more mail code examples http://www.rondebruin.nl/sendmail.htm

Ron de Bruin

ection/range in indows Live Mail or Outlook. e much more options then.

u can use the

ink on each worksheet)

Note: There is more information on the webpage


Mail the whole workbook With SendMail http://www.rondebruin.nl/mail/folder1/mail1.htm This example Send the ActiveWorkbook It Display the mail so you can look at the result You find the macro in Module1

This sub will send a newly created workbook (copy of the ActiveWorkbook). It is saving the workbook with a date/time stamp. After the file is sent the workbook will be deleted from your hard disk It Display the mail so you can look at the result You find the macro in Module1

Note: There is more information on the webpage


Mail one Sheet With SendMail http://www.rondebruin.nl/mail/folder1/mail2.htm This example Send only the activesheet It Display the mail so you can look at the result You find the macro in Module2

Mail more then one sheet with SendMail http://www.rondebruin.nl/mail/folder1/mail3.htm This example Send the sheet ReadMe and the sheet MailSheet(s) It Display the mail so you can look at the result You find the macro in Module2

Note: There is more information on the webpage


Mail Range or Selection http://www.rondebruin.nl/mail/folder1/mail4.htm This example Send the range Range("A1:K50") in a new workbook It Display the mail so you can look at the result You find the macro in Module3

This example Send the Selection in a new workbook It Display the mail so you can look at the result You find the macro in Module3

Note: There is more information on the webpage


Mail every WorkSheet with address in A1 with SendMail http://www.rondebruin.nl/mail/folder1/mail5.htm Not possible to display the mail before sending if you fill in the To line with SendMail. Before you test the code add a mail address in A1 of one or more sheets. You find the macro in Module4

Note: There is more information on the webpage


Mail a row or rows to each person in a range (SendMail) http://www.rondebruin.nl/mail/folder1/row2.htm We filter the range A17:C? for every unique name in the name column (column A in this example) For every unique name we create a new file with only the data of that person and send it to the mail address it find with the VLookup function in the worksheet "Mailinfo". Important : This example also use the sheet named "MailInfo" Note: Fill in a correct mail address for each name in the name column in the sheet "MailInfo" You find the macro in Module5

Name
Ron Dave Tom Ron Dave Tom Ron Dave Tom Ron Dave Tom Ron Dave Tom Ron Dave Tom

Note: There is more information on the webpage


Mail a row or rows to each person in a range (SendMail) http://www.rondebruin.nl/mail/folder1/row2.htm We filter the range A17:C? for every unique name in the name column (column A in this example) For every unique name we create a new file with only the data of that person and send it to the mail address it find with the VLookup function in the worksheet "Mailinfo". Important : This example also use the sheet named "MailInfo" Note: Fill in a correct mail address for each name in the name column in the sheet "MailInfo" You find the macro in Module5

Student information
Info about Ron 1 Info about Dave 1 Info about Tom 1 Info about Ron 2 Info about Dave 2 Info about Tom 2 Info about Ron 3 Info about Dave 3 Info about Tom 3 Info about Ron 4 Info about Dave 4 Info about Tom 4 Info about Ron 5 Info about Dave 5 Info about Tom 5 Info about Ron 6 Info about Dave 6 Info about Tom 6

Other Info
Other Info about Ron 1 Other Info about Dave 1 Other Info about Tom 1 Other Info about Ron 2 Other Info about Dave 2 Other Info about Tom 2 Other Info about Ron 3 Other Info about Dave 3 Other Info about Tom 3 Other Info about Ron 4 Other Info about Dave 4 Other Info about Tom 4 Other Info about Ron 5 Other Info about Dave 5 Other Info about Tom 5 Other Info about Ron 6 Other Info about Dave 6 Other Info about Tom 6

Name Ron Dave Tom

Mail address ron@test.nl dave@test.nl tom@test.nl

You might also like