Sub ReadEmails()
'Stop Screen Updates
Application.ScreenUpdating = False
' Then remember to run automatic calculations back on
Application.Calculation = xlCalculationManual
Application.EnableEvents = False
'set this to the folder
Set Olf = CreateObject("Outlook.Application").GetNamespace("MAPI").Folders(1).Folders("inbox")
i = Olf.Items.Count + 1
LR = Range("A65536").End(xlUp).Row
r = 1
Do Until r = i
subs = UCase(Olf.Items(r).Subject)
strID = Olf.Items(r).EntryID
Worksheets("Sheet1").Cells(LR, 1).Value = subs
Worksheets("Sheet1").Cells(LR, 2).Value = Date
Worksheets("Sheet1").Cells(LR, 3).Value = strID
r = r + 1
LR = LR + 1
Loop
'Stop Screen Updates
Application.ScreenUpdating = True
' Then remember to run automatic calculations back on
Application.Calculation = xlCalculationAutomatic
Application.EnableEvents = True
End Sub
Sub ReadEmails()
'Stop Screen Updates
Application.ScreenUpdating = False
' Then remember to run automatic calculations back on
Application.Calculation = xlCalculationManual
Application.EnableEvents = False
'set this to the folder
Set Olf = CreateObject("Outlook.Application").GetNamespace("MAPI").Folders(1).Folders("inbox")
i = Olf.Items.Count + 1
LR = Range("A65536").End(xlUp).Row
r = 1
Do Until r = i
subs = Olf.Items(r).Subject
daterec = Olf.Items(r).ReceivedTime
strID = Olf.Items(r).EntryID
Worksheets("Sheet1").Cells(LR, 1).Value = subs
Worksheets("Sheet1").Cells(LR, 2).Value = daterec
Worksheets("Sheet1").Cells(LR, 3).Value = strID
r = r + 1
LR = LR + 1
Loop
'Stop Screen Updates
Application.ScreenUpdating = True
' Then remember to run automatic calculations back on
Application.Calculation = xlCalculationAutomatic
Application.EnableEvents = True
End Sub