Forum

Sending Mails from ...
 
Notifications
Clear all

Sending Mails from Excel

3 Posts
3 Users
0 Reactions
82 Views
(@kc)
Posts: 1
New Member
Topic starter
 

Hi,

Hope everyone is fine.

My question is. Say there are the below five columns

docket no User dept. status Activity date activity duration
MJ/123 A standing committee 05-07-2020 64
MJ/421 B Technical with user dept. 05-08-2020 33
MJ/456 A technical with vendor 05-09-2020 2
MJ/504 C pp signing due 07-09-2020 0
MJ/512 A Technical with user dept. 02-09-2020 5

Say in sheet two I have the list of email id's against each user dept.

Now what will be the code for each occurence of cell values.

Say "status" is standing committee and depending on the values of the column "activity duration" mail ids will be sent.

now the activity duration column has the function =today()-D1

If D1 is between 5 and 10 and status = standing committee then email will be sent to the user dept. that is mentioned in B1

If D1 is greater than 10 and status is "standing committee" again mail will be sent automatically to the person that is mapped in sheet 2 against each user dept.

 

Awaiting your kind reply.

Kaushik C

 
Posted : 08/09/2020 12:06 pm
(@purfleet)
Posts: 412
Reputable Member
 

VBA and sending emails has been cover loads of times on this forum, i would suggust reading through the blogs

https://www.myonlinetraininghub.com/vba-to-create-pdf-from-excel-worksheet-then-email-it-with-outlook

 
Posted : 08/09/2020 2:20 pm
Philip Treacy
(@philipt)
Posts: 1632
Member Admin
 

Hi Kaushik,

As Purfleet said this has been covered many times, did you use the Search function at the top of the site?  Searching for 'email' in the topic title in the VBA forum returns 35 posts

Search VBA Forum for Email

like this

https://www.myonlinetraininghub.com/excel-forum/vba-macros/auto-email-through-excel

https://www.myonlinetraininghub.com/excel-forum/vba-macros/send-emails-based-on-changing-cell-values

https://www.myonlinetraininghub.com/excel-forum/vba-macros/different-email-addresses-based-on-current-sheet

Read through those to see if they already answer your question.  If you get stuck after trying to write the code then please post your workbook here.

Regards

Phil

 
Posted : 08/09/2020 8:01 pm
Share: