Getting data from Email to Excel

Estarriol

New Member
Joined
Jul 26, 2005
Messages
29
Hi all,
I'm trying to put together a backup "dashboard" in Excel.

I need a macro that does the following:


Insert a new Column at say "H" moving all columns right and in the first cell (H1) put yesterday's date.
Open email, get NEW/UNREAD emails (the date's may not be yesterday's, some of the backups finish after midnight)
Parse the data in BOTH subject AND body looking for "Success" or "Successful" (different backup software on some pc's gives different response emails, some have success in subject, others have it in body)
Get the Company Name from the subject, get the PC name from the subject
Find which row in the spreadsheet that Company Name AND PC name is and put "OK" in (Hx) where x is the Company name's and PC name's row
Mark email as READ
Then repeat for next (NEW/UNREAD) email.

Also needs to look for "Failed" in subject and body. If it find's "Fail" put "X" in (Hx) and fill the cell with red so it stands out.

Mail account is in Outlook attached to MS Exchange


TIA

Al
 

Excel Facts

Test for Multiple Conditions in IF?
Use AND(test, test, test, test) or OR(test, test, test, ...) as the logical_test argument of IF.
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,163,732
Messages
5,833,369
Members
430,206
Latest member
Sami Gaid

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
Top