VBA to send email to unique mail id given in a cell with the subsequent columns

Prince27

New Member
Joined
Nov 24, 2012
Messages
41
Hi,
There are 4 columns in excel as shown below:

[TABLE="width: 580"]
<tbody>[TR]
[TD]Email
[/TD]
[TD]Name
[/TD]
[TD]Location
[/TD]
[TD]Number
[/TD]
[/TR]
[TR]
[TD]abc@gmail.com
[/TD]
[TD]aaa
[/TD]
[TD]CA
[/TD]
[TD]123
[/TD]
[/TR]
[TR]
[TD]abc@gmail.com
[/TD]
[TD]bbb
[/TD]
[TD]TX
[/TD]
[TD]223
[/TD]
[/TR]
[TR]
[TD]xyz@gmail.com
[/TD]
[TD]ccc
[/TD]
[TD]NJ
[/TD]
[TD]333
[/TD]
[/TR]
</tbody>[/TABLE]

I need a VB Code to send separate emails to unique mail id's with column 2, 3 & 4 in a table format.(Mails should automatically send to mail id's given in column1)

1 email for each Unique mail id.


Output should be as follows:

For abc@gmail.com

[TABLE="width: 435"]
<tbody>[TR]
[TD]Name
[/TD]
[TD]Location
[/TD]
[TD]Number
[/TD]
[/TR]
[TR]
[TD]aaa
[/TD]
[TD]CA
[/TD]
[TD]123
[/TD]
[/TR]
[TR]
[TD]bbb
[/TD]
[TD]TX
[/TD]
[TD]223
[/TD]
[/TR]
</tbody>[/TABLE]

For xyz@gmail.com

[TABLE="width: 435"]
<tbody>[TR]
[TD]Name
[/TD]
[TD]Location
[/TD]
[TD]Number
[/TD]
[/TR]
[TR]
[TD]ccc
[/TD]
[TD]NJ
[/TD]
[TD]333
[/TD]
[/TR]
</tbody>[/TABLE]


Thank you for your help.
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top