Hi
At closing of 2019 we've got thread about creating something what can automatically creates email based on date in cell.
I am using something like this. I've been asked to put this solution here as quite easy and helpful.
So:
1. Data are organised like below:
A B C D E F G 1WHO body text DUE DATE ADDRESS 2Dave Just reminder 03/04/2020[email protected] 3Steve Happy Birthday pal 05/08/2020[email protected]
column C/D/E are empty and can be use to more text in particular email.
2. Macros in xlsm file:
Standard module
(if you want to recopy this macros please remove additional space in html tags, I have to add it on because firewall does not let me send html in post, check blueish lines)
as you can spot, there is few lines commented (' at start). All are related in case if you want to add picture in email. Picture path have to be set properly and then line can be uncommented.HTML Code:
BE AWARE THAT IF YOU UNCOMMENT THESE LINES AND PICTURE FILE DOES NOT EXIST, EMAIL WON'T BE CREATED!
ThisWorkbook code:
Please Login or Register to view this content.
3. Running file (TXT file with VBS extension):
strPath of course have to be set according to your structure on disk and access
4. Set schedule to run VBS file as above in Windows TaskScheduler (I've got on daily at 10:00)Please Login or Register to view this content.
VBA file should run excel file in background, excel itself should runs its macros and due to the fact that .Send parameter is set message should be send in outlook background without displaying.
Bookmarks